Topic
2 replies Latest Post - ‏2012-01-06T18:14:21Z by Ed_Hansen
Ed_Hansen
Ed_Hansen
28 Posts
ACCEPTED ANSWER

Pinned topic SCA/JMS Binding - Pausing Endpoint after Message Delivery Failure

‏2012-01-06T05:30:29Z |
In an MDB, if a RuntimeException is thrown from the onMessage method, WAS will rollback the message onto the queue. If the number of delivery failures specified in the activation spec has been met, WAS will pause the endpoint of the MDB.

I am wondering how to achieve the same effect for the JMS binding of my SCA component.

My JMS binding is configured with a custom operation selector, so the first of my methods that is called when a message lands on the queue is OperationSelector>>getOperationName. Throwing a RuntimeException from this method does not cause the message to be rolled back onto the queue. It therefore does not constitute a delivery failure, so even in the event of processing problems with multiple sequential messages, the endpoint is never paused.

Is there something else I need to do to indicate a delivery failure? Or do I need to manually rollback the message onto the queue? If so, how do I programmatically pause the endpoint?
Updated on 2012-01-06T18:14:21Z at 2012-01-06T18:14:21Z by Ed_Hansen
  • SrikISL
    SrikISL
    1 Post
    ACCEPTED ANSWER

    Re: SCA/JMS Binding - Pausing Endpoint after Message Delivery Failure

    ‏2012-01-06T06:40:56Z  in response to Ed_Hansen
    You need to specify Intent for rolling back messages for unchecked exceptions. For checked exceptions, you need to code rollback before throwing exceptions.

    Follow this for more information: http://publib.boulder.ibm.com/infocenter/wasinfo/v7r0/index.jsp?topic=%2Fcom.ibm.websphere.soafep.multiplatform.doc%2Finfo%2Fae%2Fae%2Ftsca_scajmsbinding_transactions.html
    • Ed_Hansen
      Ed_Hansen
      28 Posts
      ACCEPTED ANSWER

      Re: SCA/JMS Binding - Pausing Endpoint after Message Delivery Failure

      ‏2012-01-06T18:14:21Z  in response to SrikISL
      Excellent - thanks for your help