MDB transaction configuration


EJB programming & troubleshooting: MDB transaction configuration

  1. MDB transaction configuration (3 messages)

    I am new to JMS and MDB concepts and I need help with the following problem (server is WebLogic 702):
    JMS producer sends a message to a queue. MDB receives a message and calls a session ejb method to process a file. Message should be sent only once. File is processed in such a way that a number of lines is parsed, validated and loaded into a table of the database. I don't know how to configure the transaction management attributes of the MDB and EJB. The EJB should have a Container managed transaction setting with Never or Not Supported attribute, because batches of file processing should not be inside a transaction. Any suggestion is highly appreciated.

    Threaded Messages (3)

  2. MDB transaction configuration[ Go to top ]


    What is a Message Driven Bean?
    A message driven bean is a stateless, server-side, transaction-aware component that is driven by a Java message (javax.jms.message). It is invoked by the EJB Container when a message is received from a JMS Queue or Topic. It acts as a simple message listener.
  3. MDB transaction configuration[ Go to top ]

    You have to define the transaction attribute in the ejb-jar.xml as follows:


    Only Required or NotSupported is supported with MDB

    Here is a sample MDB application - Here is a sample MDB

    Here is an article I wrote on MDB using JCAResource Adapter

    Hope this helps

    Debu Panda
  4. MDB transaction configuration[ Go to top ]

    When would you use 'Not supported' for the transaction type?