XA and in-doubt transactions

Some events (for example, the accidental killing of a SEP) can result in 'in-doubt' transactions - where all parts of a composite transaction are not committed through all participating resource managers.

When resource managers are left with such in-doubt transactions, they are recovered by an internal transaction and reported to the console log:
CASXO0027I XA recovery committed in-doubt transaction 177969 branch 1 on RM ESMQXA4 16:17:38 
CASXO0027I XA recovery committed in-doubt transaction 177969 branch 1 on RM XADB2 16:17:38   
During start-up after such a failure, Enterprise Server reports any potential in-doubt transactions to the console log:
CASXO0029I XA log reported in-doubt transaction 177969 branch 1 16:30:33 
CASXO0029I XA log reported in-doubt transaction 249152 branch 3 16:30:33
Later during the start-up process, the resource managers are recovered and this work is reported to the console log:
CASXO0027I XA recovery committed in-doubt transaction 249152 branch 3 on RM ESMQXA4 16:30:41
CASXO0027I XA recovery committed in-doubt transaction 249152 branch 3 on RM XADB2 16:30:41

Note that during the restart, the resource managers were not aware of transaction 177969 branch 1 above because it was recovered by the internal XA recovery transaction before the crash.

The previous examples illustrated cases when the transactions were ultimately committed, but situations requiring rollback are also handled and reported:
CASXO0028I XA recovery rolled back in-doubt transaction 182303 branch 1 on RM ESMQXA4 16:18:10
CASXO0028I XA recovery rolled back in-doubt transaction 182303 branch 1 on RM XADB2 16:18:10

XA logging

XA logging is the mechanism underpinning the recovery of in-doubt transactions. XA logging is bypassed completely if:
  • There are no xa_recover() capable RM switch modules configured.
or
  • Switch modules report XA_RDONLY during xa_prepare().

Configuring the recovery of in-doubt XA transactions

By default, XA logging is enabled for qualifying resource managers which have switch modules that are configured to respond to xa_recovery() calls. The logging enables you to recover from failures that leave resource managers such as DB2 and MQ with in-doubt transactions. Depending upon your environment, logging may degrade performance. You can disable the logging as follows:
  1. In the Enterprise Server Administration page, click Edit for the enterprise server region you want to disable logging.
  2. Click the General tab.
  3. In the Configuration Information field, type:
    [ES-Environment] 
    ES_XA_LOG_SUPPRESS=Y
  4. Click Apply.
  5. Click OK.