-
1. Re: Web service - JMS transaction
jokum Apr 3, 2006 5:23 PM (in response to kconner)Yes,
I'm trying to achieve the following. Receive messages from queue. Construct an XML Doc and invoke a webservice with the xml as parameter. When there some kind of exception during invoking the webservice, the messages should stay on the queue. In the situation the messages should be acknoledged.
Johan, -
2. Re: Web service - JMS transaction
kconner Apr 4, 2006 5:20 AM (in response to kconner)Hiya Johan.
It does not appear, at least from your description, that you are attempting to enlist any transactional resources from the webservice.
If this is the case then you can catch the exception raised by the call to the webservice and process it as you see fit. You can choose to rollback the transaction, in which case the message will be redelivered to your listener, or commit the transaction having explicitly redelivered it.
The incoming message will only be acknowledged if you commit the transaction. If you want the incoming message to be acknowledged, even when the webservice fails, then you should be resending the message and calling commit on the transaction.
Kev