rvm_end_transaction(3)

NAME
rvm_end_transaction - commit transaction

SYNOPSIS

#include "rvm.h"
rvm_return_t rvm_end_transaction (tid,mode)
rvm_tid_t         *tid;  /* pointer to transaction identifier */
rvm_trans_mode_t  mode;  /* transaction commit mode */

DESCRIPTION
rvm_end_transaction commits the changes made since the transaction began. All transactions can be committed with this function, regardless of the mode they were begun with. The transaction identifier must refer to a previously initiated transaction or RVM_ETID is returned. Two commit modes are recognized: flush and no_flush. In a flush commit, the new value records for the transaction are written (flushed) to the log file. Permanence is then guaranteed upon successful return. A no_flush commit is faster than a commit with log flushing, but provides a weaker guarantee of permanence. The new value records are created, but not written to the log file. Permanence is guaranteed only when they are flushed to the log file. This can be done either by a flush-mode commit of another transaction, or by explicitly flushing the log with rvm_flush. An application can enhance performance by delaying the log flush (and permanence of changes) until a sequence of related transactions has been completed. Note that aborting the last transaction of such a sequence will not restore the original state of transactions previously committed with the no_flush option. RVM does not support nested transactions.

DIAGNOSTICS

RVM_SUCCESS
    success

RVM_ETID
    invalid transaction identifier or pointer

RVM_EMODE
    invalide transaction end mode

RVM_EINIT
    RVM not initialized

SEE ALSO
rvm_begin_transaction (3), rvm_set_range (3), rvm_modify_bytes (3), and rvm_flush (3)

AUTHOR
Hank Mashburn