#include <NdbTransaction.hpp>
Public Types | |
| enum | ExecType { NoCommit, Commit, Rollback } |
Public Member Functions | |
| NdbOperation * | getNdbOperation (const char *aTableName) |
| NdbOperation * | getNdbOperation (const NdbDictionary::Table *aTable) |
| NdbScanOperation * | getNdbScanOperation (const char *aTableName) |
| NdbScanOperation * | getNdbScanOperation (const NdbDictionary::Table *aTable) |
| NdbIndexScanOperation * | getNdbIndexScanOperation (const char *anIndexName, const char *aTableName) |
| NdbIndexScanOperation * | getNdbIndexScanOperation (const NdbDictionary::Index *anIndex, const NdbDictionary::Table *aTable) |
| NdbIndexScanOperation * | getNdbIndexScanOperation (const NdbDictionary::Index *anIndex) |
| NdbIndexOperation * | getNdbIndexOperation (const char *anIndexName, const char *aTableName) |
| NdbIndexOperation * | getNdbIndexOperation (const NdbDictionary::Index *anIndex, const NdbDictionary::Table *aTable) |
| NdbIndexOperation * | getNdbIndexOperation (const NdbDictionary::Index *anIndex) |
Execute Transaction | |
| int | execute (ExecType execType, NdbOperation::AbortOption=NdbOperation::DefaultAbortOption, int force=0) |
| int | execute (::ExecType execType,::AbortOption abortOption=::DefaultAbortOption, int force=0) |
| int | refresh () |
| void | close () |
Meta Information | |
| enum | CommitStatusType { NotStarted, Started, Committed, Aborted, NeedAbort } |
| int | getGCI (Uint64 *gciptr) |
| int | getGCI () |
| Uint64 | getTransactionId () |
| CommitStatusType | commitStatus () |
Error Handling | |
| enum | ConStatusType { NotConnected, Connecting, Connected, DisConnecting, ConnectFailure } |
| enum | SendStatusType { NotInit, InitState, sendOperations, sendCompleted, sendCOMMITstate, sendABORT, sendABORTfail, sendTC_ROLLBACK, sendTC_COMMIT, sendTC_OP } |
| enum | CompletionStatus { NotCompleted, CompletedSuccess, CompletedFailure, DefinitionFailure } |
| enum | ReturnType { ReturnSuccess, ReturnFailure } |
| enum | ListState { NotInList, InPreparedList, InSendList, InCompletedList } |
| typedef Uint64 | TimeMillis_t |
| Uint32 | theId |
| SendStatusType | theSendStatus |
| NdbAsynchCallback | theCallbackFunction |
| void * | theCallbackObject |
| Uint32 | theTransArrayIndex |
| TimeMillis_t | theStartTransTime |
| NdbError | theError |
| int | theErrorLine |
| NdbOperation * | theErrorOperation |
| Ndb * | theNdb |
| NdbTransaction * | theNext |
| NdbOperation * | theFirstOpInList |
| NdbOperation * | theLastOpInList |
| NdbOperation * | theFirstExecOpInList |
| NdbOperation * | theLastExecOpInList |
| NdbOperation * | theCompletedFirstOp |
| NdbOperation * | theCompletedLastOp |
| Uint32 | theNoOfOpSent |
| Uint32 | theNoOfOpCompleted |
| Uint32 | theMyRef |
| Uint32 | theTCConPtr |
| Uint64 | theTransactionId |
| Uint64 | theGlobalCheckpointId |
| Uint64 * | p_latest_trans_gci |
| ConStatusType | theStatus |
| enum NdbTransaction::CompletionStatus | theCompletionStatus |
| CommitStatusType | theCommitStatus |
| Uint32 | theMagicNumber |
| Uint32 | thePriority |
| ReturnType | theReturnStatus |
| bool | theTransactionIsStarted |
| bool | theInUseState |
| bool | theSimpleState |
| enum NdbTransaction::ListState | theListState |
| Uint32 | theDBnode |
| Uint32 | theNodeSequence |
| bool | theReleaseOnClose |
| Uint32 | m_db_nodes [2] |
| Uint32 | m_failed_db_nodes [2] |
| bool | m_waitForReply |
| NdbIndexScanOperation * | m_theFirstScanOperation |
| NdbIndexScanOperation * | m_theLastScanOperation |
| NdbIndexScanOperation * | m_firstExecutedScanOp |
| NdbScanOperation * | theScanningOp |
| Uint32 | theBuddyConPtr |
| bool | theBlobFlag |
| Uint8 | thePendingBlobOps |
| class | HugoOperations |
| struct | Ndb_free_list_t< NdbTransaction > |
| const NdbError & | getNdbError () const |
| NdbOperation * | getNdbErrorOperation () |
| const NdbOperation * | getNdbErrorOperation () const |
| int | getNdbErrorLine () |
| const NdbOperation * | getNextCompletedOperation (const NdbOperation *op) const |
| const NdbOperation * | readTuple (const NdbRecord *key_rec, const char *key_row, const NdbRecord *result_rec, char *result_row, NdbOperation::LockMode lock_mode=NdbOperation::LM_Read, const unsigned char *result_mask=0, const NdbOperation::OperationOptions *opts=0, Uint32 sizeOfOptions=0) |
| const NdbOperation * | insertTuple (const NdbRecord *key_rec, const char *key_row, const NdbRecord *attr_rec, const char *attr_row, const unsigned char *mask=0, const NdbOperation::OperationOptions *opts=0, Uint32 sizeOfOptions=0) |
| const NdbOperation * | insertTuple (const NdbRecord *combined_rec, const char *combined_row, const unsigned char *mask=0, const NdbOperation::OperationOptions *opts=0, Uint32 sizeOfOptions=0) |
| const NdbOperation * | updateTuple (const NdbRecord *key_rec, const char *key_row, const NdbRecord *attr_rec, const char *attr_row, const unsigned char *mask=0, const NdbOperation::OperationOptions *opts=0, Uint32 sizeOfOptions=0) |
| const NdbOperation * | writeTuple (const NdbRecord *key_rec, const char *key_row, const NdbRecord *attr_rec, const char *attr_row, const unsigned char *mask=0, const NdbOperation::OperationOptions *opts=0, Uint32 sizeOfOptions=0) |
| const NdbOperation * | deleteTuple (const NdbRecord *key_rec, const char *key_row, const NdbRecord *result_rec, char *result_row=0, const unsigned char *result_mask=0, const NdbOperation::OperationOptions *opts=0, Uint32 sizeOfOptions=0) |
| NdbScanOperation * | scanTable (const NdbRecord *result_record, NdbOperation::LockMode lock_mode=NdbOperation::LM_Read, const unsigned char *result_mask=0, const NdbScanOperation::ScanOptions *options=0, Uint32 sizeOfOptions=0) |
| NdbIndexScanOperation * | scanIndex (const NdbRecord *key_record, const NdbRecord *result_record, NdbOperation::LockMode lock_mode=NdbOperation::LM_Read, const unsigned char *result_mask=0, const NdbIndexScanOperation::IndexBound *bound=0, const NdbScanOperation::ScanOptions *options=0, Uint32 sizeOfOptions=0) |
| void | releaseCompletedOperations () |
| NdbTransaction (Ndb *aNdb) | |
| ~NdbTransaction () | |
| int | init () |
| int | executeNoBlobs (ExecType execType, NdbOperation::AbortOption=NdbOperation::DefaultAbortOption, int force=0) |
| void | setConnectedNodeId (Uint32 nodeId, Uint32 sequence) |
| void | setMyBlockReference (int) |
| void | setTC_ConnectPtr (Uint32) |
| int | getTC_ConnectPtr () |
| void | setBuddyConPtr (Uint32) |
| Uint32 | getBuddyConPtr () |
| NdbTransaction * | next () |
| void | next (NdbTransaction *) |
| ConStatusType | Status () |
| void | Status (ConStatusType) |
| Uint32 | get_send_size () |
| void | set_send_size (Uint32) |
| int | receiveDIHNDBTAMPER (NdbApiSignal *anApiSignal) |
| int | receiveTCSEIZECONF (NdbApiSignal *anApiSignal) |
| int | receiveTCSEIZEREF (NdbApiSignal *anApiSignal) |
| int | receiveTCRELEASECONF (NdbApiSignal *anApiSignal) |
| int | receiveTCRELEASEREF (NdbApiSignal *anApiSignal) |
| int | receiveTC_COMMITCONF (const class TcCommitConf *, Uint32 len) |
| int | receiveTCKEYCONF (const class TcKeyConf *, Uint32 aDataLength) |
| int | receiveTCKEY_FAILCONF (const class TcKeyFailConf *) |
| int | receiveTCKEY_FAILREF (NdbApiSignal *anApiSignal) |
| int | receiveTC_COMMITREF (NdbApiSignal *anApiSignal) |
| int | receiveTCROLLBACKCONF (NdbApiSignal *anApiSignal) |
| int | receiveTCROLLBACKREF (NdbApiSignal *anApiSignal) |
| int | receiveTCROLLBACKREP (NdbApiSignal *anApiSignal) |
| int | receiveTCINDXCONF (const class TcIndxConf *, Uint32 aDataLength) |
| int | receiveTCINDXREF (NdbApiSignal *) |
| int | receiveSCAN_TABREF (NdbApiSignal *) |
| int | receiveSCAN_TABCONF (NdbApiSignal *, const Uint32 *, Uint32 len) |
| int | doSend () |
| int | sendROLLBACK () |
| int | sendTC_HBREP () |
| int | sendCOMMIT () |
| void | setGCI (int GCI) |
| int | OpCompleteFailure (NdbOperation *) |
| int | OpCompleteSuccess () |
| void | CompletedOperations () |
| void | OpSent () |
| void | release () |
| void | releaseOperations () |
| void | releaseOps (NdbOperation *) |
| void | releaseScanOperations (NdbIndexScanOperation *) |
| bool | releaseScanOperation (NdbIndexScanOperation **listhead, NdbIndexScanOperation **listtail, NdbIndexScanOperation *op) |
| void | releaseExecutedScanOperation (NdbIndexScanOperation *) |
| void | setTransactionId (Uint64 aTransactionId) |
| void | setErrorCode (int anErrorCode) |
| void | setOperationErrorCode (int anErrorCode) |
| void | setOperationErrorCodeAbort (int anErrorCode, int abortOption=-1) |
| int | checkMagicNumber () |
| NdbOperation * | getNdbOperation (const class NdbTableImpl *aTable, NdbOperation *aNextOp=0, bool useRec=false) |
| NdbIndexScanOperation * | getNdbScanOperation (const class NdbTableImpl *aTable) |
| NdbIndexOperation * | getNdbIndexOperation (const class NdbIndexImpl *anIndex, const class NdbTableImpl *aTable, NdbOperation *aNextOp=0, bool useRec=false) |
| NdbIndexScanOperation * | getNdbIndexScanOperation (const NdbIndexImpl *index, const NdbTableImpl *table) |
| NdbOperation * | setupRecordOp (NdbOperation::OperationType type, NdbOperation::LockMode lock_mode, NdbOperation::AbortOption default_ao, const NdbRecord *key_record, const char *key_row, const NdbRecord *attribute_record, const char *attribute_row, const unsigned char *mask, const NdbOperation::OperationOptions *opts, Uint32 sizeOfOptions) |
| void | handleExecuteCompletion () |
| Uint32 | ptr2int () |
| int | report_node_failure (Uint32 id) |
| bool | hasBlobOperation () |
| void | completedFail (const char *s) |
| bool | checkState_TransId (const Uint32 *transId) const |
| void | remove_list (NdbOperation *&head, NdbOperation *) |
| void | define_scan_op (NdbIndexScanOperation *) |
| NdbTransaction (const NdbTransaction &) | |
| NdbTransaction & | operator= (const NdbTransaction &) |
| static void | sendTC_COMMIT_ACK (class TransporterFacade *, NdbApiSignal *, Uint32 transId1, Uint32 transId2, Uint32 aBlockRef) |
A transaction (represented by an NdbTransaction object) belongs to an Ndb object and is created using Ndb::startTransaction(). A transaction consists of a list of operations (represented by NdbOperation, NdbScanOperation, NdbIndexOperation, and NdbIndexScanOperation objects). Each operation access exactly one table.
After getting the NdbTransaction object, the first step is to get (allocate) an operation given the table name using one of the methods getNdbOperation(), getNdbScanOperation(), getNdbIndexOperation(), or getNdbIndexScanOperation(). Then the operation is defined. Several operations can be defined on the same NdbTransaction object, they will in that case be executed in parallell. When all operations are defined, the execute() method sends them to the NDB kernel for execution.
The execute() method returns when the NDB kernel has completed execution of all operations defined before the call to execute(). All allocated operations should be properly defined before calling execute().
A call to execute() uses one out of three types of execution:
execute() is equipped with an extra error handling parameter. There are two alternatives:
typedef Uint64 NdbTransaction::TimeMillis_t [private] |
enum NdbTransaction::CompletionStatus [private] |
enum NdbTransaction::ConStatusType [private] |
enum NdbTransaction::ListState [private] |
enum NdbTransaction::ReturnType [private] |
enum NdbTransaction::SendStatusType [private] |
| NdbTransaction::NdbTransaction | ( | Ndb * | aNdb | ) | [private] |
| NdbTransaction::~NdbTransaction | ( | ) | [private] |
| NdbTransaction::NdbTransaction | ( | const NdbTransaction & | ) | [private] |
| int NdbTransaction::checkMagicNumber | ( | ) | [private] |
| bool NdbTransaction::checkState_TransId | ( | const Uint32 * | transId | ) | const [private] |
| void NdbTransaction::close | ( | ) |
| CommitStatusType NdbTransaction::commitStatus | ( | ) |
Get the commit status of the transaction.
| void NdbTransaction::completedFail | ( | const char * | s | ) | [private] |
| void NdbTransaction::CompletedOperations | ( | ) | [private] |
| void NdbTransaction::define_scan_op | ( | NdbIndexScanOperation * | ) | [private] |
| const NdbOperation* NdbTransaction::deleteTuple | ( | const NdbRecord * | key_rec, | |
| const char * | key_row, | |||
| const NdbRecord * | result_rec, | |||
| char * | result_row = 0, |
|||
| const unsigned char * | result_mask = 0, |
|||
| const NdbOperation::OperationOptions * | opts = 0, |
|||
| Uint32 | sizeOfOptions = 0 | |||
| ) |
| int NdbTransaction::doSend | ( | ) | [private] |
| int NdbTransaction::execute | ( | ::ExecType | execType, | |
| ::AbortOption | abortOption = ::DefaultAbortOption, |
|||
| int | force = 0 | |||
| ) | [inline] |
| int NdbTransaction::execute | ( | ExecType | execType, | |
| NdbOperation::AbortOption | = NdbOperation::DefaultAbortOption, |
|||
| int | force = 0 | |||
| ) |
Executes transaction.
| execType | Execution type: ExecType::NoCommit executes operations without committing them. ExecType::Commit executes remaining operations and commits the complete transaction. ExecType::Rollback rollbacks the entire transaction. | |
| abortOption | Handling of error while excuting AbortOnError - Abort transaction if an operation fail AO_IgnoreError - Accept failing operations DefaultAbortOption - Use per-operation abort option | |
| force | When operations should be sent to NDB Kernel. (See Adaptive Send Algorithm.)
|
| int NdbTransaction::executeNoBlobs | ( | ExecType | execType, | |
| NdbOperation::AbortOption | = NdbOperation::DefaultAbortOption, |
|||
| int | force = 0 | |||
| ) | [private] |
| Uint32 NdbTransaction::get_send_size | ( | ) | [private] |
| Uint32 NdbTransaction::getBuddyConPtr | ( | ) | [private] |
| int NdbTransaction::getGCI | ( | ) |
Deprecated...in favor of getGCI(Uint64*)
| int NdbTransaction::getGCI | ( | Uint64 * | gciptr | ) |
Get global checkpoint identity (GCI) of transaction.
Each committed transaction belong to a GCI. The log for the committed transaction is saved on disk when a global checkpoint occurs.
Whether or not the global checkpoint with this GCI has been saved on disk or not cannot be determined by this method.
By comparing the GCI of a transaction with the value last GCI restored in a restarted NDB Cluster one can determine whether the transaction was restored or not.
| const NdbError& NdbTransaction::getNdbError | ( | ) | const |
Get error object with information about the latest error.
| int NdbTransaction::getNdbErrorLine | ( | ) |
Get the method number where the latest error occured.
| const NdbOperation* NdbTransaction::getNdbErrorOperation | ( | ) | const |
Get the latest NdbOperation which had an error. This method is used on the NdbTransaction object to find the NdbOperation causing an error. To find more information about the actual error, use method NdbOperation::getNdbError() on the returned NdbOperation object.
| NdbOperation* NdbTransaction::getNdbErrorOperation | ( | ) |
Get the latest NdbOperation which had an error. This method is used on the NdbTransaction object to find the NdbOperation causing an error. To find more information about the actual error, use method NdbOperation::getNdbError() on the returned NdbOperation object.
| NdbIndexOperation* NdbTransaction::getNdbIndexOperation | ( | const class NdbIndexImpl * | anIndex, | |
| const class NdbTableImpl * | aTable, | |||
| NdbOperation * | aNextOp = 0, |
|||
| bool | useRec = false | |||
| ) | [private] |
| NdbIndexOperation* NdbTransaction::getNdbIndexOperation | ( | const NdbDictionary::Index * | anIndex | ) |
Get an operation from NdbIndexOperation idlelist and get the NdbTransaction object that was fetched by startTransaction pointing to this operation.
| anIndex | An index object (fetched by NdbDictionary::Dictionary::getIndex). |
| NdbIndexOperation* NdbTransaction::getNdbIndexOperation | ( | const NdbDictionary::Index * | anIndex, | |
| const NdbDictionary::Table * | aTable | |||
| ) |
| NdbIndexOperation* NdbTransaction::getNdbIndexOperation | ( | const char * | anIndexName, | |
| const char * | aTableName | |||
| ) |
Get an operation from NdbIndexOperation idlelist and get the NdbTransaction object that was fetched by startTransaction pointing to this operation.
| anIndexName | The index name (as created by createIndex). | |
| aTableName | The table name. |
| NdbIndexScanOperation* NdbTransaction::getNdbIndexScanOperation | ( | const NdbIndexImpl * | index, | |
| const NdbTableImpl * | table | |||
| ) | [private] |
| NdbIndexScanOperation* NdbTransaction::getNdbIndexScanOperation | ( | const NdbDictionary::Index * | anIndex | ) |
Get an operation from NdbIndexScanOperation idlelist and get the NdbTransaction object which was fetched by startTransaction pointing to this operation.
| anIndex | An index object (fetched by NdbDictionary::Dictionary::getIndex). |
| NdbIndexScanOperation* NdbTransaction::getNdbIndexScanOperation | ( | const NdbDictionary::Index * | anIndex, | |
| const NdbDictionary::Table * | aTable | |||
| ) |
| NdbIndexScanOperation* NdbTransaction::getNdbIndexScanOperation | ( | const char * | anIndexName, | |
| const char * | aTableName | |||
| ) |
Get an operation from NdbIndexScanOperation idlelist and get the NdbTransaction object which was fetched by startTransaction pointing to this operation.
| anIndexName | The name of the index to use for scanning | |
| aTableName | The name of the table to scan |
| NdbOperation* NdbTransaction::getNdbOperation | ( | const class NdbTableImpl * | aTable, | |
| NdbOperation * | aNextOp = 0, |
|||
| bool | useRec = false | |||
| ) | [private] |
| NdbOperation* NdbTransaction::getNdbOperation | ( | const NdbDictionary::Table * | aTable | ) |
Get an NdbOperation for a table. Note that the operation has to be defined before it is executed.
| aTable | A table object (fetched by NdbDictionary::Dictionary::getTable) |
| NdbOperation* NdbTransaction::getNdbOperation | ( | const char * | aTableName | ) |
Get an NdbOperation for a table. Note that the operation has to be defined before it is executed.
| aTableName | The table name. |
| NdbIndexScanOperation* NdbTransaction::getNdbScanOperation | ( | const class NdbTableImpl * | aTable | ) | [private] |
| NdbScanOperation* NdbTransaction::getNdbScanOperation | ( | const NdbDictionary::Table * | aTable | ) |
Get an operation from NdbScanOperation idlelist and get the NdbTransaction object which was fetched by startTransaction pointing to this operation.
| aTable | A table object (fetched by NdbDictionary::Dictionary::getTable) |
| NdbScanOperation* NdbTransaction::getNdbScanOperation | ( | const char * | aTableName | ) |
Get an operation from NdbScanOperation idlelist and get the NdbTransaction object which was fetched by startTransaction pointing to this operation.
| aTableName | The table name. |
| const NdbOperation* NdbTransaction::getNextCompletedOperation | ( | const NdbOperation * | op | ) | const |
Get completed (i.e. executed) operations of a transaction
This method should only be used after a transaction has been executed.
This method is typically used to fetch all NdbOperation:s of a transaction to check for errors (use NdbOperation::getNdbError to fetch the NdbError object of an NdbOperation).
| op | Operation, NULL means get first operation |
| int NdbTransaction::getTC_ConnectPtr | ( | ) | [private] |
| Uint64 NdbTransaction::getTransactionId | ( | ) |
Get transaction identity.
| void NdbTransaction::handleExecuteCompletion | ( | ) | [private] |
| bool NdbTransaction::hasBlobOperation | ( | ) | [inline, private] |
| int NdbTransaction::init | ( | ) | [private] |
| const NdbOperation* NdbTransaction::insertTuple | ( | const NdbRecord * | combined_rec, | |
| const char * | combined_row, | |||
| const unsigned char * | mask = 0, |
|||
| const NdbOperation::OperationOptions * | opts = 0, |
|||
| Uint32 | sizeOfOptions = 0 | |||
| ) |
| const NdbOperation* NdbTransaction::insertTuple | ( | const NdbRecord * | key_rec, | |
| const char * | key_row, | |||
| const NdbRecord * | attr_rec, | |||
| const char * | attr_row, | |||
| const unsigned char * | mask = 0, |
|||
| const NdbOperation::OperationOptions * | opts = 0, |
|||
| Uint32 | sizeOfOptions = 0 | |||
| ) |
| void NdbTransaction::next | ( | NdbTransaction * | ) | [private] |
| NdbTransaction* NdbTransaction::next | ( | ) | [private] |
| int NdbTransaction::OpCompleteFailure | ( | NdbOperation * | ) | [private] |
| int NdbTransaction::OpCompleteSuccess | ( | ) | [private] |
| NdbTransaction& NdbTransaction::operator= | ( | const NdbTransaction & | ) | [private] |
| void NdbTransaction::OpSent | ( | ) | [private] |
| Uint32 NdbTransaction::ptr2int | ( | ) | [private] |
| const NdbOperation* NdbTransaction::readTuple | ( | const NdbRecord * | key_rec, | |
| const char * | key_row, | |||
| const NdbRecord * | result_rec, | |||
| char * | result_row, | |||
| NdbOperation::LockMode | lock_mode = NdbOperation::LM_Read, |
|||
| const unsigned char * | result_mask = 0, |
|||
| const NdbOperation::OperationOptions * | opts = 0, |
|||
| Uint32 | sizeOfOptions = 0 | |||
| ) |
| int NdbTransaction::receiveDIHNDBTAMPER | ( | NdbApiSignal * | anApiSignal | ) | [private] |
| int NdbTransaction::receiveSCAN_TABCONF | ( | NdbApiSignal * | , | |
| const Uint32 * | , | |||
| Uint32 | len | |||
| ) | [private] |
| int NdbTransaction::receiveSCAN_TABREF | ( | NdbApiSignal * | ) | [private] |
| int NdbTransaction::receiveTC_COMMITCONF | ( | const class TcCommitConf * | , | |
| Uint32 | len | |||
| ) | [private] |
| int NdbTransaction::receiveTC_COMMITREF | ( | NdbApiSignal * | anApiSignal | ) | [private] |
| int NdbTransaction::receiveTCINDXCONF | ( | const class TcIndxConf * | , | |
| Uint32 | aDataLength | |||
| ) | [private] |
| int NdbTransaction::receiveTCINDXREF | ( | NdbApiSignal * | ) | [private] |
| int NdbTransaction::receiveTCKEY_FAILCONF | ( | const class TcKeyFailConf * | ) | [private] |
| int NdbTransaction::receiveTCKEY_FAILREF | ( | NdbApiSignal * | anApiSignal | ) | [private] |
| int NdbTransaction::receiveTCKEYCONF | ( | const class TcKeyConf * | , | |
| Uint32 | aDataLength | |||
| ) | [private] |
| int NdbTransaction::receiveTCRELEASECONF | ( | NdbApiSignal * | anApiSignal | ) | [private] |
| int NdbTransaction::receiveTCRELEASEREF | ( | NdbApiSignal * | anApiSignal | ) | [private] |
| int NdbTransaction::receiveTCROLLBACKCONF | ( | NdbApiSignal * | anApiSignal | ) | [private] |
| int NdbTransaction::receiveTCROLLBACKREF | ( | NdbApiSignal * | anApiSignal | ) | [private] |
| int NdbTransaction::receiveTCROLLBACKREP | ( | NdbApiSignal * | anApiSignal | ) | [private] |
| int NdbTransaction::receiveTCSEIZECONF | ( | NdbApiSignal * | anApiSignal | ) | [private] |
| int NdbTransaction::receiveTCSEIZEREF | ( | NdbApiSignal * | anApiSignal | ) | [private] |
| int NdbTransaction::refresh | ( | ) |
Refresh Update timeout counter of this transaction in the database. If you want to keep the transaction active in the database longer than the transaction abort timeout.
| void NdbTransaction::release | ( | ) | [private] |
| void NdbTransaction::releaseCompletedOperations | ( | ) | [private] |
Release completed operations
| void NdbTransaction::releaseExecutedScanOperation | ( | NdbIndexScanOperation * | ) | [private] |
| void NdbTransaction::releaseOperations | ( | ) | [private] |
| void NdbTransaction::releaseOps | ( | NdbOperation * | ) | [private] |
| bool NdbTransaction::releaseScanOperation | ( | NdbIndexScanOperation ** | listhead, | |
| NdbIndexScanOperation ** | listtail, | |||
| NdbIndexScanOperation * | op | |||
| ) | [private] |
| void NdbTransaction::releaseScanOperations | ( | NdbIndexScanOperation * | ) | [private] |
| void NdbTransaction::remove_list | ( | NdbOperation *& | head, | |
| NdbOperation * | ||||
| ) | [private] |
| int NdbTransaction::report_node_failure | ( | Uint32 | id | ) | [private] |
| NdbIndexScanOperation* NdbTransaction::scanIndex | ( | const NdbRecord * | key_record, | |
| const NdbRecord * | result_record, | |||
| NdbOperation::LockMode | lock_mode = NdbOperation::LM_Read, |
|||
| const unsigned char * | result_mask = 0, |
|||
| const NdbIndexScanOperation::IndexBound * | bound = 0, |
|||
| const NdbScanOperation::ScanOptions * | options = 0, |
|||
| Uint32 | sizeOfOptions = 0 | |||
| ) |
Do an index range scan (optionally ordered) of a table.
The key_record describes the index to be scanned. It must be a key record for the index, ie. it must specify (at least) all the key columns of the index. And it must be created from the index to be scanned (not from the underlying table).
The result_record describes the rows to be returned from the scan. For an ordered index scan, result_record must be a key record for the index to be scanned, that is it must include at least all of the columns in the index (the reason is that the full index key is needed by NDBAPI for merge sorting the ordered rows returned from each fragment). The result_record must be created from the underlying table, not from the index to be scanned.
Both the key_record and result_record NdbRecord structures must stay in-place until the scan operation is closed.
A single IndexBound can either be specified in this call or in a separate call to NdbIndexScanOperation::setBound(). To perform a multi range read, the scan_flags in the ScanOptions structure must include SF_MULTIRANGE. Additional bounds can then be added using multiple calls to NdbIndexScanOperation::setBound().
To specify an equals bound, use the same row pointer for the low_key and high_key with the low and high inclusive bits set.
A ScanOptions structure can be passed, specifying extra options. See the definition of the ScanOptions structure for more information.
To enable backwards compatability of this interface, a sizeOfOptions parameter can be passed. This parameter indicates the size of the ScanOptions structure at the time the client was compiled, and enables detection of the use of an old ScanOptions structure. If this functionality is not required, it can be left set to zero.
| NdbScanOperation* NdbTransaction::scanTable | ( | const NdbRecord * | result_record, | |
| NdbOperation::LockMode | lock_mode = NdbOperation::LM_Read, |
|||
| const unsigned char * | result_mask = 0, |
|||
| const NdbScanOperation::ScanOptions * | options = 0, |
|||
| Uint32 | sizeOfOptions = 0 | |||
| ) |
Scan a table, using NdbRecord to read out column data.
The NdbRecord pointed to by result_record must remain valid until the scan operation is closed.
The result_mask pointer is optional, if present only columns for which the corresponding bit (by attribute id order) in result_mask is set will be retrieved in the scan. The result_mask is copied internally, so in contrast to result_record need not be valid at execute().
A ScanOptions structure can be passed, specifying extra options. See the definition of the NdbScanOperation::ScanOptions structure for more information.
To enable backwards compatability of this interface, a sizeOfOptions parameter can be passed. This parameter indicates the size of the ScanOptions structure at the time the client was compiled, and enables detection of the use of an old ScanOptions structure. If this functionality is not required, it can be left set to zero.
| int NdbTransaction::sendCOMMIT | ( | ) | [private] |
| int NdbTransaction::sendROLLBACK | ( | ) | [private] |
| static void NdbTransaction::sendTC_COMMIT_ACK | ( | class TransporterFacade * | , | |
| NdbApiSignal * | , | |||
| Uint32 | transId1, | |||
| Uint32 | transId2, | |||
| Uint32 | aBlockRef | |||
| ) | [static, private] |
| int NdbTransaction::sendTC_HBREP | ( | ) | [private] |
| void NdbTransaction::set_send_size | ( | Uint32 | ) | [private] |
| void NdbTransaction::setBuddyConPtr | ( | Uint32 | ) | [private] |
| void NdbTransaction::setConnectedNodeId | ( | Uint32 | nodeId, | |
| Uint32 | sequence | |||
| ) | [private] |
Set Connected node id and sequence no
| void NdbTransaction::setErrorCode | ( | int | anErrorCode | ) | [private] |
| void NdbTransaction::setGCI | ( | int | GCI | ) | [private] |
| void NdbTransaction::setMyBlockReference | ( | int | ) | [private] |
| void NdbTransaction::setOperationErrorCode | ( | int | anErrorCode | ) | [private] |
| void NdbTransaction::setOperationErrorCodeAbort | ( | int | anErrorCode, | |
| int | abortOption = -1 | |||
| ) | [private] |
| void NdbTransaction::setTC_ConnectPtr | ( | Uint32 | ) | [private] |
| void NdbTransaction::setTransactionId | ( | Uint64 | aTransactionId | ) | [private] |
| NdbOperation* NdbTransaction::setupRecordOp | ( | NdbOperation::OperationType | type, | |
| NdbOperation::LockMode | lock_mode, | |||
| NdbOperation::AbortOption | default_ao, | |||
| const NdbRecord * | key_record, | |||
| const char * | key_row, | |||
| const NdbRecord * | attribute_record, | |||
| const char * | attribute_row, | |||
| const unsigned char * | mask, | |||
| const NdbOperation::OperationOptions * | opts, | |||
| Uint32 | sizeOfOptions | |||
| ) | [private] |
| void NdbTransaction::Status | ( | ConStatusType | ) | [private] |
| ConStatusType NdbTransaction::Status | ( | ) | [private] |
| const NdbOperation* NdbTransaction::updateTuple | ( | const NdbRecord * | key_rec, | |
| const char * | key_row, | |||
| const NdbRecord * | attr_rec, | |||
| const char * | attr_row, | |||
| const unsigned char * | mask = 0, |
|||
| const NdbOperation::OperationOptions * | opts = 0, |
|||
| Uint32 | sizeOfOptions = 0 | |||
| ) |
| const NdbOperation* NdbTransaction::writeTuple | ( | const NdbRecord * | key_rec, | |
| const char * | key_row, | |||
| const NdbRecord * | attr_rec, | |||
| const char * | attr_row, | |||
| const unsigned char * | mask = 0, |
|||
| const NdbOperation::OperationOptions * | opts = 0, |
|||
| Uint32 | sizeOfOptions = 0 | |||
| ) |
friend class HugoOperations [friend] |
friend struct Ndb_free_list_t< NdbTransaction > [friend] |
Uint32 NdbTransaction::m_db_nodes[2] [private] |
handle transaction spanning multiple TC/db nodes
1) Bitmask with used nodes 2) Bitmask with nodes failed during op
Uint32 NdbTransaction::m_failed_db_nodes[2] [private] |
bool NdbTransaction::m_waitForReply [private] |
Uint64* NdbTransaction::p_latest_trans_gci [private] |
bool NdbTransaction::theBlobFlag [private] |
Uint32 NdbTransaction::theBuddyConPtr [private] |
NdbAsynchCallback NdbTransaction::theCallbackFunction [private] |
void* NdbTransaction::theCallbackObject [private] |
NdbOperation* NdbTransaction::theCompletedFirstOp [private] |
NdbOperation* NdbTransaction::theCompletedLastOp [private] |
Uint32 NdbTransaction::theDBnode [private] |
NdbError NdbTransaction::theError [private] |
int NdbTransaction::theErrorLine [private] |
NdbOperation* NdbTransaction::theErrorOperation [private] |
NdbOperation* NdbTransaction::theFirstExecOpInList [private] |
NdbOperation* NdbTransaction::theFirstOpInList [private] |
Uint64 NdbTransaction::theGlobalCheckpointId [private] |
Uint32 NdbTransaction::theId [private] |
bool NdbTransaction::theInUseState [private] |
NdbOperation* NdbTransaction::theLastExecOpInList [private] |
NdbOperation* NdbTransaction::theLastOpInList [private] |
enum NdbTransaction::ListState NdbTransaction::theListState [private] |
Uint32 NdbTransaction::theMagicNumber [private] |
Uint32 NdbTransaction::theMyRef [private] |
Ndb* NdbTransaction::theNdb [private] |
NdbTransaction* NdbTransaction::theNext [private] |
Uint32 NdbTransaction::theNodeSequence [private] |
Uint32 NdbTransaction::theNoOfOpCompleted [private] |
Uint32 NdbTransaction::theNoOfOpSent [private] |
Uint8 NdbTransaction::thePendingBlobOps [private] |
Uint32 NdbTransaction::thePriority [private] |
bool NdbTransaction::theReleaseOnClose [private] |
ReturnType NdbTransaction::theReturnStatus [private] |
NdbScanOperation* NdbTransaction::theScanningOp [private] |
SendStatusType NdbTransaction::theSendStatus [private] |
bool NdbTransaction::theSimpleState [private] |
ConStatusType NdbTransaction::theStatus [private] |
Uint32 NdbTransaction::theTCConPtr [private] |
Uint64 NdbTransaction::theTransactionId [private] |
bool NdbTransaction::theTransactionIsStarted [private] |
Uint32 NdbTransaction::theTransArrayIndex [private] |
Based on MySQL Cluster 7.0.10.
This page is for information only and is not maintained by MySQL or Sun Microsystems - use at your own risk. For an upto date view of the API refer to the header files included with your MySQL Cluster distribution or check the MySQL Cluster API Developer Guide.