[logback-user] Logback suddenly stopped logging

Joern Huxhorn jhuxhorn at googlemail.com
Mon Jul 5 16:27:59 CEST 2010


OMG, I wasn't aware of such an issue with IOException.

I guess that my code is suffering from the same issue. I've just implemented a small utility class for later use.
http://github.com/huxi/sulky/blob/master/sulky-io/src/main/java/de/huxhorn/sulky/io/ThreadInterruptionSafeguard.java

Please give the code a quick look and tell me if I forgot something or missed some point.

Thanks,
Joern.

On 05.07.2010, at 08:27, Andreas Dejung wrote:

> I had the same problem and I think I know why J
>  
> Solaris does interrupt IO blocked thread which then causes the OutputStreamAppender to catch the IOException in line 218 (version 0.9.24). I actually run version 0.9.18 but this part has not change so I guess it will behave the same way.
>  
> If we look at http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=4385444 InterruptedIOException should not be required by platform specification (sol)
> And log4j https://issues.apache.org/bugzilla/show_bug.cgi?id=44157 InterruptedIOException ignored by log4j
>  
> I think it should be solved the same why
>  
>     } catch (InterruptedIOException iioe){
>       //give the thread a changes to act on interruption and then carry on
>       Thread.currentThread().interrupt();
>     } catch (IOException ioe) {
>       // as soon as an exception occurs, move to non-started state
>       // and add a single ErrorStatus to the SM.
>      
>       this.started = false;
>       addStatus(new ErrorStatus("IO failure in appender", this, ioe));
>     }
>  
>  
> I could not find the jira entry mentioned in this thread therefore I write it here J
>  
> BTY the jvm option –XX:-UseVMInterruptibleIO does prevent the interruption by solaris but that’s only a workaround and not solving the problem ;)
>  
> Cheers Andy
>  
>  
> _______________________________________________
> Logback-user mailing list
> Logback-user at qos.ch
> http://qos.ch/mailman/listinfo/logback-user

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://qos.ch/pipermail/logback-user/attachments/20100705/cd952b34/attachment.html>


More information about the Logback-user mailing list