InnoDB Plugin
1.0
|
#include "univ.i"
#include "ut0byte.h"
#include "ut0lst.h"
#include "trx0trx.h"
#include "read0types.h"
#include "read0read.ic"
Go to the source code of this file.
Data Structures | |
struct | read_view_t |
struct | cursor_view_t |
Macros | |
#define | VIEW_NORMAL 1 |
#define | VIEW_HIGH_GRANULARITY 2 |
Functions | |
UNIV_INTERN read_view_t * | read_view_open_now (trx_id_t cr_trx_id, mem_heap_t *heap) |
UNIV_INTERN read_view_t * | read_view_purge_open (mem_heap_t *heap) |
UNIV_INLINE void | read_view_remove (read_view_t *view, bool own_mutex) |
UNIV_INTERN void | read_view_close_for_mysql (trx_t *trx) |
UNIV_INLINE bool | read_view_sees_trx_id (const read_view_t *view, trx_id_t trx_id)) |
UNIV_INTERN void | read_view_print (const read_view_t *view) |
UNIV_INTERN cursor_view_t * | read_cursor_view_create_for_mysql (trx_t *cr_trx) |
UNIV_INTERN void | read_cursor_view_close_for_mysql (trx_t *trx, cursor_view_t *curview) |
UNIV_INTERN void | read_cursor_set_for_mysql (trx_t *trx, cursor_view_t *curview) |
Cursor read
Created 2/16/1997 Heikki Tuuri
#define VIEW_HIGH_GRANULARITY 2 |
High-granularity read view where transaction does not see changes made by active transactions and own changes after a point in time when this read view was created.
#define VIEW_NORMAL 1 |
Read view types Normal consistent read view where transaction does not see changes made by active transactions except creating transaction.
UNIV_INTERN void read_cursor_set_for_mysql | ( | trx_t * | trx, |
cursor_view_t * | curview | ||
) |
This function sets a given consistent cursor view to a transaction read view if given consistent cursor view is not NULL. Otherwise, function restores a global read view to a transaction read view. in: consistent cursor view to be set
trx | in: transaction where cursor is set |
UNIV_INTERN void read_cursor_view_close_for_mysql | ( | trx_t * | trx, |
cursor_view_t * | curview | ||
) |
Close a given consistent cursor view for mysql and restore global read view back to a transaction read view. in: cursor view to be closed
trx | in: trx |
UNIV_INTERN cursor_view_t* read_cursor_view_create_for_mysql | ( | trx_t * | cr_trx | ) |
Create a consistent cursor view for mysql to be used in cursors. In this consistent read view modifications done by the creating transaction or future transactions are not visible. in: trx where cursor view is created
UNIV_INTERN void read_view_close_for_mysql | ( | trx_t * | trx | ) |
Closes a consistent read view for MySQL. This function is called at an SQL statement end if the trx isolation level is <= TRX_ISO_READ_COMMITTED. in: trx which has a read view
UNIV_INTERN read_view_t* read_view_open_now | ( | trx_id_t | cr_trx_id, |
mem_heap_t * | heap | ||
) |
Opens a read view where exactly the transactions serialized before this point in time are seen in the view.
cr_trx_id | in: trx_id of creating transaction, or 0 used in purge |
UNIV_INTERN void read_view_print | ( | const read_view_t * | view | ) |
Prints a read view to stderr. in: read view
UNIV_INTERN read_view_t* read_view_purge_open | ( | mem_heap_t * | heap | ) |
Makes a copy of the oldest existing read view, or opens a new. The view must be closed with ..._close.
UNIV_INLINE void read_view_remove | ( | read_view_t * | view, |
bool | own_mutex | ||
) |
Remove a read view from the trx_sys->view_list. in: true if caller owns the trx_sys_t::mutex
Remove a read view from the trx_sys->view_list.
view | in: read view, can be 0 |
own_mutex | in: true if caller owns the trx_sys_t::mutex |
UNIV_INLINE bool read_view_sees_trx_id | ( | const read_view_t * | view, |
trx_id_t | trx_id | ||
) |
Checks if a read view sees the specified transaction.
view | in: read view |
trx_id | in: trx id |