You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@netbeans.apache.org by GitBox <gi...@apache.org> on 2018/09/22 20:03:39 UTC

[GitHub] mdindoffer commented on issue #854: [NETBEANS-1197] Avoid ClosedByInterruptException in JarClassLoader

mdindoffer commented on issue #854: [NETBEANS-1197] Avoid ClosedByInterruptException in JarClassLoader
URL: https://github.com/apache/incubator-netbeans/pull/854#issuecomment-423769593
 
 
   I have to disagree with @eirikbakke's reasoning.
   
   What this PR basically does is purposefully ignoring interrupts and force-retrying the I/O action. While it may be desirable in very specific cases, it should not be a pattern applied throughout any project. That's analogous to using empty catch(Exception) constructs.
   
   Handling exceptions is a responsibility of the caller. If a higher-level code caches a negative result and leaves the system in a bad state, it's a bug in the higher-level code. If an interrupted task simply has to be completed, it should A) not be interrupted at all, or B) be restarted by the caller. Or to put it another way - fix the problems, not the symptoms.
   
   So for the alternatives:
   1. Fix the callers properly to retry the I/O operation where appropriate
   2. Fix the logic that interrupts operations, that should not be interrupted in the first place
   3. Reduce the log severity in the remaining cases, if appropriate

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: notifications-unsubscribe@netbeans.apache.org
For additional commands, e-mail: notifications-help@netbeans.apache.org

For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists