MDB using NotSupported Tx attribute

Discussions

EJB design: MDB using NotSupported Tx attribute

  1. MDB using NotSupported Tx attribute (2 messages)

    I've a stateless session bean with Required tx attribute, it does some business processing but it then puts a message on the jms queue which will be consumed by a MDB. This MDB will then needs utilize a helper object to do some time consuming in memory processing(potentially reading the database as well, but read only no updates). I want reading the message off the queue and the in memory processing without any transaction, so i'm thinking of having a NotSupported Tx attribute for MDB, after the result of the in memory processing it then will call another stateless session ejb to do some business processing, this ejb is goin to have a Required attribute. Can anyone suggest that using this model, is there a chance to loose message, any suggestions that a CMT or a BMT should be utilized to cater for not loosing any messages, trying messages for a certain amount of re-tries and not processing duplicates. Cheers
  2. Unless the MDB has a required attribute, surely you'll lose messages and won't be able to roll back and retry if needed. Perhaps a better way of doing this is to leave the MDB with txn required, put another method in the SLSB and do the in-memory work in that method instead. Once that's completed, another ejb method with the txn required attribute is called. That way, you won't lose any messages. Pete
  3. Re: MDB using NotSupported Tx attribute[ Go to top ]

    The method in the SLSB which does the in-memory work, would have a txn attribute of not-supported.