Drizzled Public API Documentation

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