Previous Topic Next topic Print topic


XA Return Codes

Restriction: This topic applies only when the Enterprise Server feature is enabled.

As with flag definitions, all transaction managers and resource managers must ensure interchangeability by using these return codes, defined in the xa.h header.

ax_() return codes (transaction manager reports to resource manager)

#define Code Description
TM_JOIN 2 Caller is joining existing transaction branch
TM_RESUME 1 Caller is resuming association with suspended transaction branch
TM_OK 0 Normal execution
TMER_TMERR -1 An error occurred in the transaction manager
TMER_INVAL -2 Invalid arguments were given
TMER_PROTO -3 Routine invoked in an improper context

xa_() return codes (resource manager reports to transaction manager)

#define Code Description
XA_RBBASE 100 The inclusive lower bound of the rollback codes
XA_RBROLLBACK XA_RBBASE The rollback was caused by an unspecified reason
XA_RBCOMMFAIL XA_RBBASE+1 The rollback was caused by a communication failure
XA_RBDEADLOCK XA_RBBASE+2 A deadlock was detected
XA_RBINTEGRITY XA_RBBASE+3 A condition that violates the integrity of the resources was detected
XA_RBOTHER XA_RBBASE+4 Tthe resource manager rolled back the transaction branch for a reason not on this list
XA_RBPROTO XA_RBBASE+5 A protocol error occurred in the resource manager
XA_RBTIMEOUT XA_RBBASE+6 A transaction branch took too long
XA_RBTRANSIENT XA_RBBASE+7 May retry the transaction branch
XA_RBEND XA_RBTRANSIENT The inclusive upper bound of the rollback codes
XA_NOMIGRATE 9 Resumption must occur where suspension occurred
XA_HEURHAZ 8 The transaction branch may have been heuristically completed
XA_HEURCOM 7 The transaction branch has been heuristically committed
XA_HEURRB 6 The transaction branch has been heuristically rolled back
XA_HEURMIX 5 The transaction branch has been heuristically committed and rolled back
XA_RETRY 4 Routine returned with no effect and may be reissued
XA_RDONLY 3 The transaction branch was read-only and has been committed
XA_OK 0 Normal execution
XAER_ASYNC -2 Asynchronous operation already outstanding
XAER_RMERR -3 A resource manager error occurred in the transaction branch
XAER_NOTA -4 The XID is not valid
XAER_INVAL -5 Invalid arguments were given
XAER_PROTO -6 Routine invoked in an improper context
XAER_RMFAIL -7 Resource manager unavailable
XAER_DUPID -8 The XID already exists
XAER_OUTSIDE -9 Resource manager doing work outside
Previous Topic Next topic Print topic