Transaction Management

The Transaction Management page of the Edit Enterprise Bean Wizard will display as part of the wizard if you have selected Transaction Management from the Configuration Options page of this wizard.

Use the Transaction Management page to indicate whether the bean's are managed by the bean or by the container. If the transactions are managed by the container, you can also define what level of transaction support is required for each method in each interface.

  1. In the Transaction Management panel, select either or transactions.
  2. If container management is selected, you need to select the Transaction Attribute for each method. Select the type of interface for which to define transaction management. When one of the interface types is selected in the Show column, the method names corresponding to that interface will display in the table to the right. The Local Home and Remote Home choices will display no methods when the enterprise bean is a session bean.

    For Message-Driven Beans, the radio buttons listing the types of interfaces will not display.

  3. Select the for each method from the drop-down list in the Transaction Attribute column. The default value for all methods is Required. Select the Transaction Attribute link above to learn more about the Transaction Attribute options.

    For Message-Driven Beans, the Transaction Attributes are limited to Required or Not Supported. For Session Beans, the Transaction Attributes are limited to Required, Required New, and Mandatory.

    If you are not familiar with transaction attributes, or are not sure which one to choose for a particular method, you should enter 'Required' in the Transaction Attribute column. In general, 'Required' provides a reasonable default for container-managed transactions. Transaction attributes may be entered later after your enterprise bean has been created.

  4. Click on the folded paper icon in the rightmost column to enter a description for each method.

Copyright 1999-2003 Sun Microsystems, Inc. All Rights Reserved.