BEA Logo BEA WebLogic Server Release 6.1

  Corporate Info  |  News  |  Solutions  |  Products  |  Partners  |  Services  |  Events  |  Download  |  How To Buy

   BEA WebLogic Server Administration Guide:   Previous topic   |   Next topic   |   Contents   |  Index

 

Managing Transactions

 

The following topics are discussed:

This section provides guidelines for configuring and managing transactions through the Administration Console. For information on configuring JDBC connection pools to allow JDBC drivers to participate in distributed transactions, see " Managing JDBC Connectivity" in the Administration Guide.

Overview of Transaction Management

The Administration Console provides an interface to the tools that allow you to enable and configure WebLogic Server features, including the JavaTransaction API (JTA). To invoke the Administration Console, see the procedures provided in Configuring WebLogic Servers and Clusters. The configuration process involves specifying values for attributes. These attributes define various aspects of the transaction environment, including the following:

Before configuring your transaction environment, you should be familiar with the J2EE components that can participate in transactions, such as EJBs, JDBC, and JMS.

For more information about configuring J2EE components, see the applicable sections of this document and the Administration Console online help.

Configuring Transactions

The Administration Console provides default values for all JTA configuration attributes. If you specify an invalid value for any configuration attribute, the WebLogic Server does not boot when you restart it.

Configuration settings for JTA are applicable at the domain level. This means that configuration attribute settings apply to all servers within a domain. Monitoring and logging tasks for JTA are performed at the server level.

Once you have configured WebLogic JTA and any transaction participants, the system can perform transactions using the JTA API and the WebLogic JTA extensions.

You can configure any transaction attributes before running applications (static configuration) or, with one exception, at application run time (dynamic configuration). The TransactionLogFilePrefix attribute must be set before running applications.

To configure transaction attributes, complete the following procedure:

  1. Start the Administration Console.

  2. Select the domain node in the left pane. The Configuration tab for the domain is displayed by default.

  3. Click the JTA tab.

  4. For each attribute, specify a value or, if available, accept the default value.

  5. Click Apply to store new attribute values.

  6. Ensure that the Transaction Log File Prefix attribute is set when you configure the server. For more information on setting the logging attribute, see Monitoring and Logging Transactions..

Table 13-1 briefly describes the transaction attributes available with WebLogic Server. For detailed information about attributes, and valid and default values for them, see the Domain topic in the Administration Console online help.

Table 13-1 Transaction Attributes

Attribute

Description

Timeout Seconds

The time, in seconds, a transaction may be active before the system forces a rollback.

Abandon Timeout Seconds

The maximum time, in seconds, that a transaction coordinator persists in attempting to complete a transaction.

Before Completion Iteration Limit

The number of beforeCompletion callbacks that are processed before the system forces a rollback.

Max Transactions

The maximum number of transactions that may be active on a particular server at one time.

Max Unique Name Statistics

The maximum number of unique transaction names that may be tracked by a server at one time.

Forget Heuristics

A Boolean value specifying whether the transaction manager should instruct a resource to forget any transaction with a heuristic outcome.

Monitoring and Logging Transactions

The Administration Console allows you to monitor transactions and to specify the transaction log file prefix. Monitoring and logging tasks are performed at the server level. Transaction statistics are displayed for a specific server and each server has a transaction log file.

To display transaction statistics and to set the prefix for the transaction log files, complete the following procedure:

  1. Start the Administration Console.

  2. Click the server node in the left pane.

  3. Select a specific server in the left pane.

  4. Click the Monitoring tab.

  5. Click the JTA tab. Totals for transaction statistics are displayed in the JTA dialog. (You can also click the monitoring text links to monitor transactions by resource or by name, or to monitor all active transactions.)

  6. Click the Logging tab.

  7. Click the JTA tab.

  8. Enter a transaction log file prefix then click on Apply to save the attribute setting.

For detailed information on monitoring and logging values and attributes, see the Server topic in the Administration Console online help.

Moving a Server to Another Machine

When an applications server is moved to another machine, it must be able to locate the transaction log files on the new disk. For this reason, we recommend moving the transaction log files to the new machine before starting the server there. By doing so you can ensure that recovery runs properly. If the pathname is different on the new machine, update the TransactionLogFilePrefix attribute with the new path before starting the server.

When migrating transaction logs after a server failure, make all transaction log files available on the new machine before starting the server there. You can accomplish this by storing transaction log files on a dual-ported disk available to both machines. As in the case of a planned migration, update the TransactionLogFilePrefix attribute with the new path before starting the server if the pathname is different on the new machine. It is important to ensure that all transaction log files are available on the new machine before the server is started there. Otherwise, transactions in the process of being committed at the time of a crash might not be resolved correctly, resulting in application data inconsistencies.

 

Back to Top