ASG
IBM
Zystems
Cressida
Icon
Netflexity
 
  MQSeries.net
Search  Search       Tech Exchange      Education      Certifications      Library      Info Center      SupportPacs      LinkedIn  Search  Search                                                                   FAQ  FAQ   Usergroups  Usergroups
 
Register  ::  Log in Log in to check your private messages
 
RSS Feed - WebSphere MQ Support RSS Feed - Message Broker Support

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » Callableflow - exception handling

Post new topic  Reply to topic
 Callableflow - exception handling « View previous topic :: View next topic » 
Author Message
lonesheep
PostPosted: Thu Dec 07, 2017 12:00 pm    Post subject: Callableflow - exception handling Reply with quote

Novice

Joined: 12 Sep 2017
Posts: 21

Hi,

I maybe doing something really stupid, but I'm trying to figure out if an exception can be returned to the calling flow with the calling flow knowing it has returned in error without having to examine the response (i.e. automatically routing to the catch / failure terminals).

For instance if I have Flow A, which invokes the callable Flow B.

In the execution of Flow B I have the following nodes;
CallableInput
Compute
CallableReply

In the compute node I just throw an exception, i.e.

THROW USER EXCEPTION CATALOG 'MyCatalog' MESSAGE 1234 VALUES ('eSQL throw error');

Control is returned to Flow A, but the flow continues down the "out" terminal rather than routing to the "failure" or "catch" terminals.

Regards
Back to top
View user's profile Send private message
martinb
PostPosted: Tue Dec 12, 2017 12:29 am    Post subject: Reply with quote

Master

Joined: 09 Nov 2006
Posts: 210
Location: UK

Hi

When using a CallableFlowInvoke I do see an exception thrown in the called flow propagated in the ExceptionList from the CallableFlowInvoke's Failure terminal.

Note I don't have any catch logic, or the Catch terminal of the Callable Input node in my called flow wired.
Back to top
View user's profile Send private message
emarshah
PostPosted: Tue Dec 12, 2017 9:14 pm    Post subject: Re: Callableflow - exception handling Reply with quote

Newbie

Joined: 27 Feb 2010
Posts: 4

lonesheep wrote:
Hi,

Control is returned to Flow A, but the flow continues down the "out" terminal rather than routing to the "failure" or "catch" terminals.



True that, callable invoke doesn't come back with exception-list, though it comes with message as required.

As this callable message flows aren't complete replica of calling message flows inside other message flow.

What could be better option is to always handle the exception in the flow itself and return back with some sensible message to the calling message flow. Depending on your exception handling pattern, you can store it and reply back with proper error message in response.

I am not sure, whether the current behavior of callable message flows is intended or its a bug.

Thanks.
Back to top
View user's profile Send private message Send e-mail
martinb
PostPosted: Tue Dec 12, 2017 11:30 pm    Post subject: Reply with quote

Master

Joined: 09 Nov 2006
Posts: 210
Location: UK

Hi,

Quote:
True that, callable invoke doesn't come back with exception-list,...
...
I am not sure, whether the current behavior of callable message flows is intended or its a bug.


To be clear that is not the behavior I see with 10.0.0.11.

An uncaught exception in the called flow will results in the CallableFlowInvoke's Failure terminal propagating with ExceptionList.
Back to top
View user's profile Send private message
emarshah
PostPosted: Wed Dec 13, 2017 1:06 pm    Post subject: Reply with quote

Newbie

Joined: 27 Feb 2010
Posts: 4

martinb wrote:
Hi,

To be clear that is not the behavior I see with 10.0.0.11.

An uncaught exception in the called flow will results in the CallableFlowInvoke's Failure terminal propagating with ExceptionList.


I am using
Version: 10.0.0.8
Build id: 10.0.0.8-20170307-0628

and can't see the ExceptionList being build up in the message from Failure terminal. I will upgrade and can comment further on this.
Back to top
View user's profile Send private message Send e-mail
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » Callableflow - exception handling
Jump to:  



You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
Protected by Anti-Spam ACP
 
 


Theme by Dustin Baccetti
Powered by phpBB © 2001, 2002 phpBB Group

Copyright © MQSeries.net. All rights reserved.