Details
-
Bug
-
Resolution: Cannot Reproduce
-
Minor
-
None
-
None
-
None
-
None
-
java 1.6
logback 0.9.18
slf4j 1.5.11
Description
Given: e = EOFException, if I run e.printStackTrace() I get:
java.io.EOFException
at java.io.ObjectInputStream$PeekInputStream.readFully(ObjectInputStream.java:2281)
at java.io.ObjectInputStream$BlockDataInputStream.readShort(ObjectInputStream.java:2750)
at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:780)
at java.io.ObjectInputStream.<init>(ObjectInputStream.java:280)
When I log this same exception under Logback I get:
java.io.EOFException: null
at java.io.ObjectInputStream$PeekInputStream.readFully(ObjectInputStream.java:2281) [na:1.6.0_18]
at java.io.ObjectInputStream$BlockDataInputStream.readShort(ObjectInputStream.java:2750) [na:1.6.0_18]
at java.io.ObjectInputStream.readStreamHeader(ObjectInputStream.java:780) [na:1.6.0_18]
at java.io.ObjectInputStream.<init>(ObjectInputStream.java:280) [na:1.6.0_18]
I see two problems with the logback version:
- It prints "null" after EOFException when an exception message is not set. I am expecting the same output as printStackTrace()
- It is missing debugging information (file and line numbers) as seen in printStackTrace()