I was messing around with something that was resulting in
AlreadyClosedException being thrown and I noticed that we weren't
tracking the exception that caused it. I found this in
ByteBufferIndexInput:

   // the unused parameter is just to silence javac about unused variables
   AlreadyClosedException alreadyClosed(RuntimeException unused) {
-    return new AlreadyClosedException("Already closed: " + this);
+    return new AlreadyClosedException("Already closed: " + this, unused);
   }

and added the cause there, which helped me find and fix my wicked
ways. Is there a reason we decided not to wrap the "unused"
RuntimeException there?

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org
For additional commands, e-mail: dev-h...@lucene.apache.org

Reply via email to