Commit an XA Transaction
/admin/v1/xa-transaction/{id}
Request
- application/json
-
id(required): string
Global transaction ID (GTRID) of the XA transaction. This is a unique ID which you can use to track the transaction.
Response
- application/json
200 Response
object
-
branches:
array branches
-
status:
string
Allowed Values:
[ "TX_OK", "TX_ROLLBACK", "TX_MIXED", "TX_HAZARD", "TX_PROTOCOL_ERROR", "TX_ERROR", "TX_FAIL", "TX_COMMITTED" ]
-
txid:
string
object
-
branchId:
string
-
returnCode:
string
Allowed Values:
[ "XA_RBROLLBACK", "XA_RBCOMMFAIL", "XA_RBDEADLOCK", "XA_RBINTEGRITY", "XA_RBOTHER", "XA_RBPROTO", "XA_RBTIMEOUT", "XA_RBTRANSIENT", "XA_NOMIGRATE", "XA_HEURHAZ", "XA_HEURCOM", "XA_HEURRB", "XA_HEURMIX", "XA_RETRY", "XA_RDONLY", "XA_OK", "XAER_ASYNC", "XAER_RMERR", "XAER_NOTA", "XAER_INVAL", "XAER_PROTO", "XAER_RMFAIL" ]
-
status:
string
Allowed Values:
[ "Enlisted", "Prepared", "Committed", "Rolledback", "HeuristicallyCompleted", "HeuristicallyRolledback" ]
-
url:
string
400 Response
401 Response
404 Response
412 Response
Examples
cURL Command
The following example shows how to commit an XA transaction by submitting a PUT
request on the XA transaction ID using cURL. For more information about cURL, see Use cURL.
Enter the command on a single line. Line breaks are used in this example for readability.
curl -X PUT -H "Authorization:Bearer $OTMM_COOKIE" https://192.0.2.1:8080/admin/v1/xa-transaction/e6808684-5d8c-4ad0-90d2-345a225d0f02
-
OTMM_COOKIE
is the name of the variable in which you stored the authentication cookie earlier. For information about retrieving the authentication cookie and storing it in a variable, see Authenticate. -
192.0.2.1:8080
is an example REST endpoint URL. Change this value to the REST endpoint URL to access the Istio ingress gateway in your environment. For information about finding out REST endpoint URL for your site, see Send Requests. -
e6808684-5d8c-4ad0-90d2-345a225d0f02
is an example value for the global transaction ID (GTRID). Replace this value with the GTRID of an XA transaction in your environment.
No response is returned for this request.