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 » Rethrow the original exception

Post new topic  Reply to topic
 Rethrow the original exception « View previous topic :: View next topic » 
Author Message
prasannanb
PostPosted: Mon May 18, 2015 9:56 pm    Post subject: Rethrow the original exception Reply with quote

Apprentice

Joined: 17 Apr 2009
Posts: 35

I have below nodes in the flow
MQInput->compute(1)->MQoutput

I have to handle the parsing exception happening in compute node(1).
So, have connected the failure terminal of the compute node(1) to another compute node(2).
But, other than parsing exception, any other failure happening, I have to re-throw the original exception back to the MQinput node so that the error handler connected tothe MQInput node can handle that.

How can I achieve this in compute node(2)
Back to top
View user's profile Send private message
Vitor
PostPosted: Tue May 19, 2015 4:56 am    Post subject: Re: Rethrow the original exception Reply with quote

Grand High Poobah

Joined: 11 Nov 2005
Posts: 26093
Location: Texas, USA

prasannanb wrote:
How can I achieve this in compute node(2)


Check to see if the exception being processed is a parser exception, process if it is, rethrow it if it isn't.

Simple.
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
prasannanb
PostPosted: Tue May 19, 2015 9:11 pm    Post subject: Reply with quote

Apprentice

Joined: 17 Apr 2009
Posts: 35

Thanks for the reply.
But my question is how to re throw the orginal exception from the compute node which I have connected to the failure terminal of other compute node?
Back to top
View user's profile Send private message
Vitor
PostPosted: Wed May 20, 2015 4:36 am    Post subject: Reply with quote

Grand High Poobah

Joined: 11 Nov 2005
Posts: 26093
Location: Texas, USA

prasannanb wrote:
But my question is how to re throw the orginal exception from the compute node which I have connected to the failure terminal of other compute node?


Really?
_________________
Honesty is the best policy.
Insanity is the best defence.
Back to top
View user's profile Send private message
mqjeff
PostPosted: Wed May 20, 2015 5:06 am    Post subject: Reply with quote

Grand Master

Joined: 25 Jun 2008
Posts: 17447

prasannanb wrote:
Thanks for the reply.
But my question is how to re throw the orginal exception from the compute node which I have connected to the failure terminal of other compute node?


How do you throw exceptions in other languages?

What command in ESQL could possibly serve the same purpose?

What do you do with a ball, once you've caught it?
Back to top
View user's profile Send private message
rekarm01
PostPosted: Sat May 30, 2015 2:37 am    Post subject: Re: Rethrow the original exception Reply with quote

Grand Master

Joined: 25 Jun 2008
Posts: 1415

prasannanb wrote:
other than parsing exception, any other failure happening, I have to re-throw the original exception back to the MQinput node so that the error handler connected to the MQInput node can handle that.

How can I achieve this in compute node(2)

compute node(2) cannot re-throw the original exception. The best that it can do is to use the ExceptionList contents to create and throw a new (and therefore different) exception.

The only means to selectively catch or rethrow an exception in ESQL is with the RESIGNAL statement, and only within the context of a DECLARE HANDLER statement. That would have to be in compute node(1). Within a DECLARE HANDLER statement, there is no information about the exception in the ExceptionList; the only information available is what the SQLCODE, SQLSTATE, SQLNATIVEERROR, and SQLERRORTEXT functions might provide. So, it may be difficult to distinguish parsing exceptions from other exceptions.

Another option may be to split up the code in compute node(1) into two separate compute nodes, so that the code likely to generate parsing exceptions is in one compute node, and the code likely to generate other exceptions is in a different compute node.
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic  Reply to topic Page 1 of 1

MQSeries.net Forum Index » WebSphere Message Broker (ACE) Support » Rethrow the original exception
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.