Veritas NetBackup™ DataStore SDK Programmer's Guide for XBSA 1.1.0
- Introduction to NetBackup XBSA
- How to set up the SDK
- Using the NetBackup XBSA interface
- NetBackup XBSA data structures
- NetBackup XBSA environment
- XBSA sessions and transactions
- Creating a NetBackup XBSA application
- How to build an XBSA application
- How to run a NetBackup XBSA application
- API reference
- Function calls
- Function specifications
- Type definitions
- Process flow and troubleshooting
- How to use the sample files
- Support and updates
- Appendix A. Register authorized locations
BSABeginTxn
Begin a transaction.
SYNOPSIS
#include <xbsa.h>
int BSABeginTxn(BSA_Handle bsaHandle)
DESCRIPTION
The BSABeginTxn() call indicates to the NetBackup XBSA interface the beginning of one or more actions that are executed as an atomic unit, that is, all of the actions will succeed or none will succeed. An action can be assumed to be either a single function call or a series of function calls that are made for a particular purpose.
For example, a BSACreateObject() call followed by a number of BSASendData() calls and terminated by a BSAEndData() call can be considered to be a single action.
In normal use, a BSABeginTxn() call is always coupled with a subsequent BSAEndTxn() call. If BSATerminate() is called during a transaction, the transaction is aborted.
If BSA_SERVICE_HOST has not been specified before calling BSABeginTxn(), the default NetBackup server is determined and the feature is checked for a valid license key. The feature_ID is the default DataStore feature_ID unless a specific NetBackup feature_ID has been specified using NBBSA_FEATURE_ID. If a valid license is not found, the transaction returns a NBBSA_RC_FEATURE_NOT_LICENSED error and not open the transaction.
Nested transactions are not supported.
PARAMETERS
BSA_Handle bsaHandle (I) | This parameter is the handle that associates this call with a previous BSAInit() call. |
RETURN VALUE
The following return codes are returned by this function:
BSA_RC_ABORT_SYSTEM_ERROR | System detected error, operation aborted. |
BSA_RC_INVALID_CALL_SEQUENCE | The sequence of API calls is incorrect. Nested transactions are not supported. |
NBBSA_RC_FEATURE_NOT_LICENSED | The license for the requested feature is not available. |
BSA_RC_INVALID_HANDLE | The handle used to associate this call with a previous BSAInit() call is invalid. |
BSA_RC_SUCCESS | The function succeeded. |