dsmEndTxnEx
The dsmEndTxnEx function call provides group leader object ID information for you to use with the dsmGroupHandler function call. It is an extension of the dsmEndTxn function call.
Syntax
dsInt16_t dsmEndTxnEx (dsmEndTxnExIn_t *dsmEndTxnExInP
dsmEndTxnExOut_t *dsmEndTxnExOutP); Parameters
- dsmEndTxnExIn_t *dsmEndTxnExInP (I)
- This structure contains the following parameters:
- dsmHandle
- The handle that identifies the session and associates it with subsequent IBM® Storage Protect calls.
- dsUint8_t vote (I)
- Indicates whether or not the application client commits all the
actions that are done between the previous dsmBeginTxn call and this
call. The possible values are:
UseDSM_VOTE_COMMIT /* commit current transaction */ DSM_VOTE_ABORT /* roll back current transaction */DSM_VOTE_ABORTonly if your application has found a reason to stop the transaction.
- dsmEndTxnExOut_t *dsmEndTxnExOutP (O)
- This structure contains the following parameters:
- dsUint16_t *reason (O)
- If the call to dsmEndTxnEx ends with an error or the value of
vote is not agreed to, this parameter has a reason code indicating why the
vote failed. Tip: The return code for the call might be zero, and the reason code might be non-zero. Therefore, the application client must always check for errors on both the return code and the reason (
if (rc || reason)) before you can assume a successful completion.If the application specifies a vote of DSM_VOTE_ABORT, the reason code is DSM_RS_ABORT_BY_CLIENT (3). See API return codes source file: dsmrc.h for a list of the possible reason codes. Numbers 1 through 50 in the return codes list are reserved for the reason codes. If the server ends the transaction, the return code is DSM_RC_CHECK_REASON_CODE. In this case, the reason value contains more information on the cause of the abort.
- groupLeaderObjId
- The group leader object ID that is returned when the DSM_ACTION_OPEN flag is used with the dsmGroupHandler call.
Return codes
The return code numbers are provided in parentheses ( ).
| Return code | Explanation |
|---|---|
| DSM_RC_INVALID_VOTE (2011) | The value that was specified for vote is invalid. |
| DSM_RC_CHECK_REASON_CODE (2302) | The transaction was aborted. Check the reason field. |
| DSM_RC_ABORT_STGPOOL_COPY_CONT_NO (241) | The write to one of the copy storage pools failed, and the IBM Storage Protect storage pool option COPYCONTINUE was set to NO. The transaction terminates. |
| DSM_RC_ABORT_RETRY_SINGLE_TXN (242) | During a simultaneous-write operation, an object in the transaction is going to a destination with different copy storage pools. End the current transaction and send each object again in its own transaction. |