MySQL 5.6.14 Source Code Document
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
trx0types.h File Reference
#include "ut0byte.h"
Include dependency graph for trx0types.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  trx_savept_t

Macros

#define TRX_ID_FMT   IB_ID_FMT
#define TRX_ID_MAX_LEN   17
#define TRX_ID_MAX   IB_ID_MAX

Typedefs

typedef ib_id_t row_id_t
typedef ib_id_t trx_id_t
typedef ib_id_t roll_ptr_t
typedef ib_id_t undo_no_t
typedef byte trx_sysf_t
typedef byte trx_rsegf_t
typedef byte trx_usegf_t
typedef byte trx_ulogf_t
typedef byte trx_upagef_t
typedef byte trx_undo_rec_t

Enumerations

enum  trx_que_t { TRX_QUE_RUNNING, TRX_QUE_LOCK_WAIT, TRX_QUE_ROLLING_BACK, TRX_QUE_COMMITTING }
enum  trx_state_t { TRX_STATE_NOT_STARTED, TRX_STATE_ACTIVE, TRX_STATE_PREPARED, TRX_STATE_COMMITTED_IN_MEMORY }
enum  trx_dict_op_t { TRX_DICT_OP_NONE = 0, TRX_DICT_OP_TABLE = 1, TRX_DICT_OP_INDEX = 2 }
enum  trx_rb_ctx { RB_NONE = 0, RB_NORMAL, RB_RECOVERY_PURGE_REC, RB_RECOVERY }

Detailed Description

Transaction system global type definitions

Created 3/26/1996 Heikki Tuuri

Definition in file trx0types.h.

Macro Definition Documentation

#define TRX_ID_FMT   IB_ID_FMT

printf(3) format used for printing DB_TRX_ID and other system fields

Definition at line 32 of file trx0types.h.

#define TRX_ID_MAX   IB_ID_MAX

Maximum transaction identifier

Definition at line 123 of file trx0types.h.

#define TRX_ID_MAX_LEN   17
maximum length that a formatted trx_t::id could take, not including

the terminating NUL character.

Definition at line 36 of file trx0types.h.

Typedef Documentation

typedef ib_id_t roll_ptr_t

Rollback pointer (DB_ROLL_PTR, DATA_ROLL_PTR)

Definition at line 118 of file trx0types.h.

typedef ib_id_t row_id_t

Row identifier (DB_ROW_ID, DATA_ROW_ID)

Definition at line 114 of file trx0types.h.

typedef ib_id_t trx_id_t

Transaction identifier (DB_TRX_ID, DATA_TRX_ID)

Definition at line 116 of file trx0types.h.

typedef byte trx_rsegf_t

Rollback segment header

Definition at line 135 of file trx0types.h.

typedef byte trx_sysf_t

File objects Transaction system header

Definition at line 133 of file trx0types.h.

typedef byte trx_ulogf_t

Undo log header

Definition at line 139 of file trx0types.h.

typedef byte trx_undo_rec_t

Undo log record

Definition at line 144 of file trx0types.h.

typedef byte trx_upagef_t

Undo log page header

Definition at line 141 of file trx0types.h.

typedef byte trx_usegf_t

Undo segment header

Definition at line 137 of file trx0types.h.

typedef ib_id_t undo_no_t

Undo number

Definition at line 120 of file trx0types.h.

Enumeration Type Documentation

Type of data dictionary operation

Enumerator:
TRX_DICT_OP_NONE 

The transaction is not modifying the data dictionary.

TRX_DICT_OP_TABLE 

The transaction is creating a table or an index, or dropping a table. The table must be dropped in crash recovery. This and TRX_DICT_OP_NONE are the only possible operation modes in crash recovery.

TRX_DICT_OP_INDEX 

The transaction is creating or dropping an index in an existing table. In crash recovery, the data dictionary must be locked, but the table must not be dropped.

Definition at line 56 of file trx0types.h.

enum trx_que_t

Transaction execution states when trx->state == TRX_STATE_ACTIVE

Enumerator:
TRX_QUE_RUNNING 

transaction is running

TRX_QUE_LOCK_WAIT 

transaction is waiting for a lock

TRX_QUE_ROLLING_BACK 

transaction is rolling back

TRX_QUE_COMMITTING 

transaction is committing

Definition at line 39 of file trx0types.h.

enum trx_rb_ctx

Rollback contexts

Enumerator:
RB_NONE 

no rollback

RB_NORMAL 

normal rollback

RB_RECOVERY_PURGE_REC 

rolling back an incomplete transaction, in crash recovery, rolling back an INSERT that was performed by updating a delete-marked record; if the delete-marked record no longer exists in an active read view, it will be purged

RB_RECOVERY 

rolling back an incomplete transaction, in crash recovery

Definition at line 99 of file trx0types.h.

Transaction states (trx_t::state)

Definition at line 48 of file trx0types.h.