0 Replies Latest reply on Aug 5, 2008 10:40 AM by G Pache

    JMS with transacted sessions and error queues

    G Pache Newbie


      I wanted to implement the following error handling behaviour:

      * In:
      a transacted jboss internal jms queue

      * processing:
      a custom service that may throw either ActionProcessingFaultException or a RuntimeException.
      Upon an exception the system shell catch the exception and write it as a TextMessage in a custom format into an error queue.
      The transaction on the incoming jms queue should only be rolled back if there had been a fault sending the ErrorMessage to the ErrorQueue. (commit upon successful processing or sucessfull sending of error).

      How can I implement a behaviour like this in JBossESB?

      If I take a look at


      it seems hard to me to implement the error handling strategy from above, since:
      If an action throws any Exception, ActionProcessingPipeline#process() always will end up either rethrowing exception or returning "false"; that is rolling back the transaction.

      Does there exist any approach of plugging in a custom error handler?
      What would by the concept of JBossESB in order to achieve a behaviour as described above (without distributed transactions).


      G. Pache