[Top] [Prev] [Next] [Bottom]

tpgetlev(3)

tpgetlev(3)

Name

tpgetlev-routine for checking if a transaction is in progress

Synopsis

#include <atmi.h> 
int tpgetlev()

Description

tpgetlev() returns to the caller the current transaction level. Currently, the only levels defined are 0 and 1.

Return Values

Upon successful completion, tpgetlev() returns either a 0 to indicate that no transaction is in progress, or 1 to indicate that a transaction is in progress; otherwise, tpgetlev() returns \-1 on error and sets tperrno to indicate the error condition.

Errors

Under the following conditions, tpgetlev() fails and sets tperrno to:

[TPEPROTO]
tpgetlev() was called in an improper context.

[TPESYSTEM]
A BEA TUXEDO system error has occurred. The exact nature of the error is written to a log file.

[TPEOS]
An operating system error has occurred.

Notices

When using tpbegin(3), tpcommit(3) and tpabort(3) to delineate a BEA TUXEDO system transaction, it is important to remember that only the work done by a resource manager that meets the XA interface (and is linked to the caller appropriately) has transactional properties. All other operations performed in a transaction are not affected by either tpcommit(3) or tpabort(3). See buildserver(1) for details on linking resource managers that meet the XA interface into a server such that operations performed by that resource manager are part of a BEA TUXEDO system transaction.

See Also

tpabort(3), tpbegin(3), tpcommit(3), tpscmt(3)



[Top] [Prev] [Next] [Bottom]