[ 
https://issues.apache.org/activemq/browse/SM-1310?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=42582#action_42582
 ] 

Guillaume Nodet commented on SM-1310:
-------------------------------------

I have a doubt here: you say you throw a fault which is a throwable, but not an 
exception ? Usually, this would mean it inherits from Error instead of 
Exception.
I'm not sure if this is a good idea to catch Errors like OOM or such....
Can you provide a bit more details on your use case ?

> Catch throwables and not only Exceptions in BaseLifeCycle.onMessageExchange
> ---------------------------------------------------------------------------
>
>                 Key: SM-1310
>                 URL: https://issues.apache.org/activemq/browse/SM-1310
>             Project: ServiceMix
>          Issue Type: Bug
>          Components: servicemix-common
>    Affects Versions: 3.1.2
>            Reporter: Gianfranco Boccalon
>             Fix For: 3.2.3, 3.3
>
>
> When extending the ProviderEndPoint class, if the code throws a Throwable 
> (not an Exception), the method BaseLifeCycle.onMessageExchange doesn't catch 
> the exception because it catches only Exceptions.
> In these cases no messages are sent over the NMR.
> If I surround my code with a try/catch, it doesnt work also, because I send a 
> fault message and the ProviderEndPoint tries to send the normal message.
> It's possible to change the catch block in BaseLifeCycle.onMessageExchange to 
> manage also Throwables ? 

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.

Reply via email to