reef-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Markus Weimer (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (REEF-864) Make exception handling consistent
Date Thu, 17 Dec 2015 21:05:46 GMT

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

Markus Weimer commented on REEF-864:
------------------------------------

I like the list, in general. Some comments:

{quote}
Log and (re)throw. Doing both at the same time is sometimes considered an antipattern (relevant
check). So we need to discuss if REEF really needs this. 
{quote}

Please start a thread on the dev list to drive this to consensus.

{quote}
Forbid catching general exceptions: Error, RuntimeException, Throwable, Exception. 
{quote}

We'll need exemptions from this. We promise to catch *all* exceptions thrown by a task and
send them to the driver, for instance.

Also, the list doesn't cover something we currently strive to do: When throwing an exception,
log it first. I am not even convinced we should be doing that. But for now, it is our coding
practice. Is there any literature in the work you reviewed that would suggest what to do about
that?


> Make exception handling consistent
> ----------------------------------
>
>                 Key: REEF-864
>                 URL: https://issues.apache.org/jira/browse/REEF-864
>             Project: REEF
>          Issue Type: Improvement
>          Components: Build infrastructure, Documentation
>            Reporter: Sergey Dudoladov
>            Assignee: Sergey Dudoladov
>
> The recent [OSDI paper | https://www.usenix.org/conference/osdi14/technical-sessions/presentation/yuan]
suggest that many failures in distributed systems arise from 3 trivial mistake in exception
handling:
> 1) the handler is empty
> 2) the handler silently aborts
> 3) the handler contains phrases like “TODO” and “FIXME”, i.e. is knowingly incomplete
> The authors propose [their own checker|https://github.com/diy1/aspirator] for these cases,
but we can try to enforce any of these rules via checkstyle, for example.



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

Mime
View raw message