drizzle
C++ MySQL-protocol-compatible database server
Loading...
Searching...
No Matches
trx0roll.h
Go to the documentation of this file.
1/*****************************************************************************
2
3Copyright (C) 1996, 2009, Innobase Oy. All Rights Reserved.
4
5This program is free software; you can redistribute it and/or modify it under
6the terms of the GNU General Public License as published by the Free Software
7Foundation; version 2 of the License.
8
9This program is distributed in the hope that it will be useful, but WITHOUT
10ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
11FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.
12
13You should have received a copy of the GNU General Public License along with
14this program; if not, write to the Free Software Foundation, Inc., 51 Franklin
15St, Fifth Floor, Boston, MA 02110-1301 USA
16
17*****************************************************************************/
18
19/**************************************************/
25
26#pragma once
27#ifndef trx0roll_h
28#define trx0roll_h
29
30#include "univ.i"
31#include "trx0trx.h"
32#include "trx0types.h"
33#include "mtr0mtr.h"
34#include "trx0sys.h"
35
36#define trx_roll_free_all_savepoints(s) trx_roll_savepoints_free((s), NULL)
37
38/*******************************************************************/
43UNIV_INTERN
44ibool
46/*========*/
47 const trx_t* trx);
48/*******************************************************************/
51UNIV_INTERN
54/*============*/
55 trx_t* trx);
56/*******************************************************************/
58UNIV_INTERN
61/*=====================*/
62/*******************************************************************/
64UNIV_INTERN
65void
67/*==============*/
68 trx_undo_arr_t* arr);
69/*******************************************************************/
72UNIV_INLINE
75/*======================*/
76 trx_undo_arr_t* arr,
77 ulint n);
78/***********************************************************************/
80UNIV_INTERN
81void
83/*==================*/
84 trx_t* trx);
85/********************************************************************/
93UNIV_INTERN
96/*========================*/
97 trx_t* trx,
98 undo_no_t limit,
99 roll_ptr_t* roll_ptr,
100 mem_heap_t* heap);
101/********************************************************************/
106UNIV_INTERN
107ibool
109/*=================*/
110 trx_t* trx,
111 undo_no_t undo_no);
112/*******************************************************************/
114UNIV_INTERN
115void
117/*=================*/
118 trx_t* trx,
119 undo_no_t undo_no);
120/*********************************************************************/
122UNIV_INTERN
123void
125/*=========*/
126 trx_t* trx,
127 trx_sig_t* sig,
128 que_thr_t** next_thr);
133/*******************************************************************/
138UNIV_INTERN
139void
141/*============================*/
142 ibool all);
144/*******************************************************************/
151UNIV_INTERN
152os_thread_ret_t
154/*================================*/
155 void* arg);
158/****************************************************************/
160UNIV_INTERN
161void
163/*===========================*/
164 que_t* graph,
165 trx_t* trx,
166 que_thr_t** next_thr);
172/****************************************************************/
178UNIV_INTERN
179que_t*
181/*=================*/
182 trx_t* trx);
183/*********************************************************************/
186UNIV_INTERN
189/*=============*/
190 mem_heap_t* heap);
191/***********************************************************/
194UNIV_INTERN
195que_thr_t*
197/*==============*/
198 que_thr_t* thr);
199/*******************************************************************/
202UNIV_INTERN
203int
205/*===================*/
206 trx_t* trx);
207/*******************************************************************/
210UNIV_INTERN
211int
213/*=================================*/
214 trx_t* trx);
215/*******************************************************************/
218UNIV_INTERN
219int
221/*===========================*/
222 trx_t* trx,
223 trx_savept_t* savept);
226/*******************************************************************/
235UNIV_INTERN
236ulint
238/*================================*/
239 trx_t* trx,
240 const char* savepoint_name,
241 ib_int64_t* mysql_binlog_cache_pos);
247/*******************************************************************/
253UNIV_INTERN
254ulint
256/*====================*/
257 trx_t* trx,
258 const char* savepoint_name,
259 ib_int64_t binlog_cache_pos);
263
264/*******************************************************************/
269UNIV_INTERN
270ulint
272/*============================*/
273 trx_t* trx,
274 const char* savepoint_name);
275
276/*******************************************************************/
278UNIV_INTERN
279void
281/*=====================*/
282 trx_t* trx,
283 trx_named_savept_t* savep);
284
285/*******************************************************************/
288UNIV_INTERN
289void
291/*=====================*/
292 trx_t* trx,
293 trx_named_savept_t* savep);
296
304
307
314
322
333
348
349#ifndef UNIV_NONINL
350#include "trx0roll.ic"
351#endif
352
353#endif
enum roll_node_state state
Definition trx0roll.h:326
que_common_t common
Definition trx0roll.h:325
trx_savept_t savept
Definition trx0roll.h:329
trx_savept_t savept
Definition trx0roll.h:337
ib_int64_t mysql_binlog_cache_pos
Definition trx0roll.h:339
trx_undo_inf_t * infos
Definition trx0roll.h:311
mem_heap_t * heap
Definition trx0roll.h:312
undo_no_t undo_no
Definition trx0roll.h:301
UNIV_INTERN void trx_undo_rec_release(trx_t *trx, undo_no_t undo_no)
Definition trx0roll.cc:1046
UNIV_INTERN void trx_rollback_or_clean_recovered(ibool all)
Definition trx0roll.cc:537
UNIV_INTERN os_thread_ret_t trx_rollback_or_clean_all_recovered(void *arg)
Definition trx0roll.cc:611
UNIV_INTERN que_thr_t * trx_rollback_step(que_thr_t *thr)
Definition trx0roll.cc:1316
roll_node_state
Definition trx0roll.h:316
@ ROLL_NODE_WAIT
Definition trx0roll.h:319
@ ROLL_NODE_SEND
Definition trx0roll.h:317
UNIV_INTERN int trx_general_rollback_for_mysql(trx_t *trx, trx_savept_t *savept)
Definition trx0roll.cc:65
UNIV_INTERN ibool trx_is_recv(const trx_t *trx)
Definition trx0roll.cc:387
UNIV_INTERN ulint trx_rollback_to_savepoint_for_mysql(trx_t *trx, const char *savepoint_name, ib_int64_t *mysql_binlog_cache_pos)
Definition trx0roll.cc:237
UNIV_INTERN roll_node_t * roll_node_create(mem_heap_t *heap)
Definition trx0roll.cc:1295
UNIV_INTERN trx_undo_rec_t * trx_roll_pop_top_rec_of_trx(trx_t *trx, undo_no_t limit, roll_ptr_t *roll_ptr, mem_heap_t *heap)
Definition trx0roll.cc:899
UNIV_INTERN ulint trx_release_savepoint_for_mysql(trx_t *trx, const char *savepoint_name)
Definition trx0roll.cc:359
UNIV_INTERN trx_savept_t trx_savept_take(trx_t *trx)
Definition trx0roll.cc:399
UNIV_INTERN void trx_finish_rollback_off_kernel(que_t *graph, trx_t *trx, que_thr_t **next_thr)
Definition trx0roll.cc:1226
UNIV_INTERN ulint trx_savepoint_for_mysql(trx_t *trx, const char *savepoint_name, ib_int64_t binlog_cache_pos)
Definition trx0roll.cc:302
UNIV_INTERN int trx_rollback_last_sql_stat_for_mysql(trx_t *trx)
Definition trx0roll.cc:158
UNIV_INLINE trx_undo_inf_t * trx_undo_arr_get_nth_info(trx_undo_arr_t *arr, ulint n)
UNIV_INTERN ibool trx_undo_rec_reserve(trx_t *trx, undo_no_t undo_no)
Definition trx0roll.cc:1026
UNIV_INTERN void trx_undo_arr_free(trx_undo_arr_t *arr)
Definition trx0roll.cc:666
UNIV_INTERN void trx_roll_try_truncate(trx_t *trx)
Definition trx0roll.cc:805
UNIV_INTERN int trx_rollback_for_mysql(trx_t *trx)
Definition trx0roll.cc:129
UNIV_INTERN void trx_rollback(trx_t *trx, trx_sig_t *sig, que_thr_t **next_thr)
Definition trx0roll.cc:1066
UNIV_INTERN void trx_roll_savepoints_free(trx_t *trx, trx_named_savept_t *savep)
Definition trx0roll.cc:202
UNIV_INTERN que_t * trx_roll_graph_build(trx_t *trx)
Definition trx0roll.cc:1140
UNIV_INTERN void trx_roll_savepoint_free(trx_t *trx, trx_named_savept_t *savep)
Definition trx0roll.cc:184
UNIV_INTERN trx_undo_arr_t * trx_undo_arr_create(void)
Definition trx0roll.cc:636
byte trx_undo_rec_t
Definition trx0types.h:112
struct roll_node_struct roll_node_t
Definition trx0types.h:60
ib_id_t undo_no_t
Definition trx0types.h:89
struct trx_sig_struct trx_sig_t
Definition trx0types.h:48
struct trx_savept_struct trx_savept_t
Definition trx0types.h:92
struct trx_undo_inf_struct trx_undo_inf_t
Definition trx0types.h:56
ib_id_t trx_id_t
Definition trx0types.h:85
ib_id_t roll_ptr_t
Definition trx0types.h:87
struct trx_undo_arr_struct trx_undo_arr_t
Definition trx0types.h:54
struct trx_named_savept_struct trx_named_savept_t
Definition trx0types.h:64
#define UT_LIST_NODE_T(TYPE)
Definition ut0lst.h:73