curator-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Mike Drob (JIRA)" <>
Subject [jira] [Commented] (CURATOR-219) Avoid use of Throwable
Date Wed, 24 Jun 2015 18:45:05 GMT


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|],
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:
>             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

View raw message