Java Mailing List Archive

http://www.junlu.com/

Home » Home (12/2007) » JBoss User Help »

[jboss-user] [EJB 3.0] - Re: EJB3 and Timeout.

scott.stark@jboss.org

2007-08-07


The timeout specified in jboss.xml is only used if the EJB3 container needs to create a new transaction when the method in the session bean is called. A new transaction is only created in the following two cases:

- the transaction attribute is Required and there is no transaction running
- the transaction attribute is RequiresNew

The transaction attribute is Required by default, but can be overriden in the ejb-jar.xml (<container-transaction> element) or with the @TransactionAttribute annotation.

In your application, probably a transaction is started with the default timeout when the MDB's onMessage method is invoked, and that same transaction is used by your session bean.

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4071746#4071746

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4071746
_______________________________________________
jboss-user mailing list
jboss-user@(protected)
https://lists.jboss.org/mailman/listinfo/jboss-user
©2008 junlu.com - Jax Systems, LLC, U.S.A.