lucene-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From markrmil...@apache.org
Subject [5/7] lucene-solr:master: tests: add class name for tracked objects
Date Sun, 19 Feb 2017 22:02:48 GMT
tests: add class name for tracked objects


Project: http://git-wip-us.apache.org/repos/asf/lucene-solr/repo
Commit: http://git-wip-us.apache.org/repos/asf/lucene-solr/commit/f7201f23
Tree: http://git-wip-us.apache.org/repos/asf/lucene-solr/tree/f7201f23
Diff: http://git-wip-us.apache.org/repos/asf/lucene-solr/diff/f7201f23

Branch: refs/heads/master
Commit: f7201f23e7948d901bf334efe6776db6e101f39c
Parents: bb12b6c
Author: markrmiller <markrmiller@apache.org>
Authored: Sun Feb 19 15:23:55 2017 -0500
Committer: markrmiller <markrmiller@apache.org>
Committed: Sun Feb 19 15:23:55 2017 -0500

----------------------------------------------------------------------
 .../java/org/apache/solr/common/util/ObjectReleaseTracker.java | 6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/lucene-solr/blob/f7201f23/solr/solrj/src/java/org/apache/solr/common/util/ObjectReleaseTracker.java
----------------------------------------------------------------------
diff --git a/solr/solrj/src/java/org/apache/solr/common/util/ObjectReleaseTracker.java b/solr/solrj/src/java/org/apache/solr/common/util/ObjectReleaseTracker.java
index 2d7c514..bbd666a 100644
--- a/solr/solrj/src/java/org/apache/solr/common/util/ObjectReleaseTracker.java
+++ b/solr/solrj/src/java/org/apache/solr/common/util/ObjectReleaseTracker.java
@@ -39,7 +39,7 @@ public class ObjectReleaseTracker {
   public static boolean track(Object object) {
     StringWriter sw = new StringWriter();
     PrintWriter pw = new PrintWriter(sw);
-    new ObjectTrackerException().printStackTrace(pw);
+    new ObjectTrackerException(object.getClass().getName()).printStackTrace(pw);
     OBJECTS.put(object, sw.toString());
     return true;
   }
@@ -98,7 +98,9 @@ public class ObjectReleaseTracker {
   }
   
   private static class ObjectTrackerException extends RuntimeException {
-    
+    ObjectTrackerException(String msg) {
+      super(msg);
+    }
   }
 
 }


Mime
View raw message