Drizzled Public API Documentation

row0undo.h
Go to the documentation of this file.
1 /*****************************************************************************
2 
3 Copyright (C) 1997, 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 row0undo_h
28 #define row0undo_h
29 
30 #include "univ.i"
31 #include "mtr0mtr.h"
32 #include "trx0sys.h"
33 #include "btr0types.h"
34 #include "btr0pcur.h"
35 #include "dict0types.h"
36 #include "trx0types.h"
37 #include "que0types.h"
38 #include "row0types.h"
39 
40 /********************************************************************/
43 UNIV_INTERN
46 /*=================*/
47  trx_t* trx,
48  que_thr_t* parent,
49  mem_heap_t* heap);
50 /***********************************************************/
57 UNIV_INTERN
58 ibool
60 /*==========================*/
61  undo_node_t* node);
62 /***********************************************************/
66 UNIV_INTERN
67 que_thr_t*
69 /*==========*/
70  que_thr_t* thr);
72 /* A single query thread will try to perform the undo for all successive
73 versions of a clustered index record, if the transaction has modified it
74 several times during the execution which is rolled back. It may happen
75 that the task is transferred to another query thread, if the other thread
76 is assigned to handle an undo log record in the chain of different versions
77 of the record, and the other thread happens to get the x-latch to the
78 clustered index record at the right time.
79  If a query thread notices that the clustered index record it is looking
80 for is missing, or the roll ptr field in the record doed not point to the
81 undo log record the thread was assigned to handle, then it gives up the undo
82 task for that undo log record, and fetches the next. This situation can occur
83 just in the case where the transaction modified the same record several times
84 and another thread is currently doing the undo for successive versions of
85 that index record. */
86 
88 enum undo_exec {
100 };
101 
110  ulint rec_type;
120  ulint cmpl_info;
136 };
137 
138 
139 #ifndef UNIV_NONINL
140 #include "row0undo.ic"
141 #endif
142 
143 #endif