[ 
https://issues.apache.org/jira/browse/CURATOR-219?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14599938#comment-14599938
 ] 

Mike Drob commented on CURATOR-219:
-----------------------------------

I'm commenting on the issue instead of the pull request because I think this 
might be better suited as a macro-level discussion.

If an OOM is thrown, or worse, something like [Unknown 
Error|http://docs.oracle.com/javase/7/docs/api/java/lang/UnknownError.html], 
then it can't be Curator's responsibility to log and continue on as if nothing 
happened. Curator is not a long lived server process that needs to stay up no 
matter the circumstances. It is a client library, and we need to be responsible 
about propagating errors so that whatever application is using us can make 
informed decisions.

In my experience with operational systems, I would have never wanted something 
to just log OoM and continue running. This is almost guaranteed to cause bigger 
problems later.

> Avoid use of Throwable
> ----------------------
>
>                 Key: CURATOR-219
>                 URL: https://issues.apache.org/jira/browse/CURATOR-219
>             Project: Apache Curator
>          Issue Type: Bug
>            Reporter: Mike Drob
>            Assignee: Jordan Zimmerman
>             Fix For: awaiting-response
>
>
> We liberally catch {{Throwable}} in our code, which can mask more troubling 
> issues like {{OutOfMemory}} or other errors. In most cases we should be 
> catching Exception instead.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to