O'Reilly logo

Special Edition Using Enterprise JavaBeans™ 2.0 by Brian Keeton, Chuck Cavaness

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

Using Container-Managed Transactions

The recommended way to manage transactions in an EJB application is to let the container manage them for you. This is known as container-managed transaction demarcation and it allows you to direct the control of transactions using a declarative syntax. Instead of making calls to a UserTransaction object programmatically, you can determine how the boundaries of transactions should be defined through entries in the deployment descriptor for an EJB. This approach instructs the container to make calls to the transaction manager (through the TransactionManager interface) to start and stop transactions on your behalf.

The first thing to understand about container-managed transaction demarcation is why it’s useful. ...

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