O'Reilly logo

Java EE 7 Developer Handbook by Peter A. Pilgrim

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Transaction services

JTA provides transaction support to EJB and now in Java EE 7 to CDI managed beans annotated with @Transactional. The EJB specification provides declarative services to session and singleton beans. In the EJB container, the transactions are either Container-Managed Transactions (CMT) or Bean-Managed Transactions (BMT).

Container-Managed Transactions (CMT)

Container-Managed Transactions are normally annotated on EJBs with the declaration @javax.ejb.TransactionAttribute. This annotation can be applied to the type or to individual methods. It accepts a @javax.ejb.TransactionAttributeType enumeration value.

For CDI managed beans the JTA 1.2 specification provides a brand new annotation @javax.transactional.Transactional, to elevate ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required