You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@commons.apache.org by "Henri Yandell (JIRA)" <ji...@apache.org> on 2014/04/10 10:53:20 UTC

[jira] [Updated] (LANG-967) Code should never catch and ignore all Throwables

     [ https://issues.apache.org/jira/browse/LANG-967?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Henri Yandell updated LANG-967:
-------------------------------

    Component/s: lang.exception.*

> Code should never catch and ignore all Throwables
> -------------------------------------------------
>
>                 Key: LANG-967
>                 URL: https://issues.apache.org/jira/browse/LANG-967
>             Project: Commons Lang
>          Issue Type: New Feature
>          Components: lang.exception.*
>            Reporter: Sebb
>             Fix For: Patch Needed
>
>
> Code should never catch and ignore all Throwables - ThreadDeath and VirtualMachineError must be rethrown.
> It would be useful to provide a method to enforce this behaviour.
> For example,. as is done by the Tomcat method \[1] with source here \[2]
> Sample usage:
> {code}
> try {
>     reader.close();
> } catch (Throwable u) {
>     ExceptionUtils.handleThrowable(u);
> }
> {code}
> \[1] org.apache.tomcat.util.ExceptionUtils#handleThrowable()
> \[2] https://svn.apache.org/repos/asf/tomcat/trunk/java/org/apache/tomcat/util/ExceptionUtils.java



--
This message was sent by Atlassian JIRA
(v6.2#6252)