[Version 5.0.2]Configuring transactional deployment attributes using the Application Assembly Tool

Use this task to configure the transactional deployment descriptor attributes associated with an EJB or Web module, to enable a J2EE application to use transactions.

Why and when to perform this task

To set transactional attributes in the deployment descriptor for an application component (enterprise bean or servlet), complete the following steps:

Steps for this task

  1. Start the Application Assembly Tool.
  2. Create or edit the application EAR file.
    For example, to change attributes of an existing application, click File-> Open then select the EAR file.
  3. In the navigation pane, select the component instance; for example:
    • For a session bean, expand ejb_module_instance-> Session beans then select the bean instance.
    • For a servlet, expand web_application-> Web Components then select the servlet instance.
    A property dialog notebook for the component is displayed in the property pane.
  4. In the property pane, select the Advanced tab.
  5. Set the Transaction type attribute, which defines the transactional manner in which the container invokes a method.
    You can set this attribute to Container or Bean, as follows:
    • For a session bean to use container-managed transactions, set Container
    • For a session bean to use bean-managed transactions, set Bean
    • For an entity bean, set Container
    • For a Web component (servlet), set Bean
  6. In the property pane, select the IBM Extensions tab.
  7. Configure J2EE component extensions attributes for extended local transaction containment.
    To enable management of local transaction containments, configure the following EJB extensions attributes. These attributes configure, for the component, the behavior of the container's local transaction containment (LTC) environment that the container establishes whenever a global transaction is not present.
    Boundary
    Specifies the duration of a local transaction context. You can set this attribute to Bean method or ActivitySession, as described in Entity bean assembly settings.

    Note: The ActivitySession option is not supported in the web container.

    Resolution control
    Specifies how the local transaction is to be resolved before the local transaction context ends: by the application through user code or by the EJB container. You can set this attribute to either Application or ContainerAtBoundary, as described in Entity bean assembly settings.
    Unresolved action
    Specifies the action that the container must take when the local transaction context scope ends, if resources are uncommitted by an application in a local transaction and the Resolution control is set to Application. You can set this attribute to either Commit or Rollback, as described in Entity bean assembly settings.

    For a value of Commit, the container will take the commit action only in the absence of an un-handled exception. If the application method executing under the local transaction context ends with an exception, then the local transaction context is rolled back by the container. (This is the same behavior as for global transactions.)

  8. [For EJB components only] For container-managed transactions, configure how the container must manage the transaction boundaries when delegating a method invocation to an enterprise bean's business method:
    1. In the navigation pane, select Container Transactions.
      This displays a table of the methods for enterprise beans.
    2. For each method of the enterprise bean set the Transaction attribute attribute to an appropriate value, as defined in Container transaction assembly settings.

    If the application uses ActivitySessions, how the container manages transaction boundaries when delegating a method invocation depends on both the Transaction attribute attribute, set here, and the ActivitySession kind attribute, as described in Setting EJB module ActivitySession deployment attributes with the Application Assembly Tool. For more detail about the relationship between these two properties, see Combining transaction and ActivitySession container policies.


Related tasks
Developing components to use transactions
Configuring transaction properties for an application server
Related reference
Using local transactions
Combining transaction and ActivitySession container policies



Searchable topic ID:   tjta_entra1
Last updated: Jun 21, 2007 8:07:48 PM CDT    WebSphere Business Integration Server Foundation, Version 5.0.2
http://publib.boulder.ibm.com/infocenter/wasinfo/index.jsp?topic=/com.ibm.wasee.doc/info/ee/ae/tjta_entra1.html

Library | Support | Terms of Use | Feedback