SQL data field and tuple.
dberr_t
Definition: db0err.h:39
Data dictionary global types.
size_t size(const char *const c)
Definition: base64.h:46
void que_graph_free_recursive(que_node_t *node)
Frees a query graph, but not the heap where it was created.
Definition: que0que.cc:362
void que_thr_move_to_run_state_for_mysql(que_thr_t *thr, trx_t *trx)
Moves a thread from another state to the QUE_THR_RUNNING state.
Definition: que0que.cc:725
constexpr uint32_t QUE_NODE_CONTROL_STAT
Definition: que0que.h:367
static dtype_t * que_node_get_data_type(que_node_t *node)
Gets pointer to the value data type field of a graph node.
constexpr uint32_t QUE_NODE_PURGE
Definition: que0que.h:381
static que_node_t * que_node_list_get_last(que_node_t *node_list)
constexpr uint32_t QUE_FORK_PROCEDURE_CALL
Definition: que0que.h:356
static que_node_t * que_node_get_next(que_node_t *node)
Gets the next list node in a list of query graph nodes.
constexpr uint32_t QUE_NODE_ASSIGNMENT
Definition: que0que.h:389
que_cur_t
From where the cursor position is counted.
Definition: que0que.h:237
@ QUE_CUR_START
Definition: que0que.h:237
@ QUE_CUR_END
Definition: que0que.h:237
@ QUE_CUR_NOT_DEFINED
Definition: que0que.h:237
constexpr uint32_t QUE_FORK_EXECUTE
Definition: que0que.h:354
static ulint que_node_get_val_buf_size(que_node_t *node)
Gets the value buffer size of a graph node.
constexpr uint32_t QUE_NODE_UPDATE
Definition: que0que.h:372
static dfield_t * que_node_get_val(que_node_t *node)
Gets pointer to the value dfield of a graph node.
constexpr uint32_t QUE_NODE_ROLLBACK
Definition: que0que.h:380
que_thr_t * que_fork_start_command(que_fork_t *fork)
Starts execution of a command in a query fork.
Definition: que0que.cc:277
constexpr uint32_t QUE_FORK_BEING_FREED
Definition: que0que.h:364
constexpr uint32_t QUE_NODE_WHILE
Definition: que0que.h:388
constexpr uint32_t QUE_FORK_INVALID
Definition: que0que.h:363
constexpr uint32_t QUE_NODE_FETCH
Definition: que0que.h:390
void que_thr_stop_for_mysql_no_error(que_thr_t *thr, trx_t *trx)
A patch for MySQL used to 'stop' a dummy query thread used in MySQL select, when there is no error or...
Definition: que0que.cc:746
constexpr uint32_t QUE_THR_MAGIC_N
Definition: que0que.h:297
constexpr uint32_t QUE_NODE_SYMBOL
Definition: que0que.h:382
dberr_t que_eval_sql(pars_info_t *info, const char *sql, trx_t *trx)
Evaluate the given SQL.
Definition: que0que.cc:1040
constexpr uint32_t QUE_FORK_UPDATE
Definition: que0que.h:349
constexpr uint32_t QUE_THR_MAGIC_FREED
Definition: que0que.h:298
void que_run_threads(que_thr_t *thr)
Run a query thread.
Definition: que0que.cc:995
void que_thr_stop_for_mysql(que_thr_t *thr)
A patch for MySQL used to 'stop' a dummy query thread used in MySQL.
Definition: que0que.cc:687
constexpr uint32_t QUE_FORK_RECOVERY
Definition: que0que.h:358
void que_init(void)
Initialise the query sub-system.
Definition: que0que.cc:1072
que_thr_t * que_thr_create(que_fork_t *parent, mem_heap_t *heap, row_prebuilt_t *prebuilt)
Creates a query graph thread node.
Definition: que0que.cc:158
static que_thr_t * que_fork_get_first_thr(que_fork_t *fork)
Gets the first thr in a fork.
constexpr uint32_t QUE_FORK_SELECT_NON_SCROLL
Definition: que0que.h:346
constexpr uint32_t QUE_NODE_CURSOR
Definition: que0que.h:373
static ulint que_node_get_type(const que_node_t *node)
Gets the type of a graph node.
constexpr uint32_t QUE_NODE_EXIT
Definition: que0que.h:397
static ulint que_node_list_get_len(que_node_t *node_list)
Gets a query graph node list length.
static bool que_thr_peek_stop(que_thr_t *thr)
Checks if graph, trx, or session is in a state where the query thread should be stopped.
void que_graph_free(que_t *graph)
Frees a query graph.
Definition: que0que.cc:509
constexpr uint32_t QUE_FORK_PURGE
Definition: que0que.h:353
constexpr uint32_t QUE_NODE_CALL
Definition: que0que.h:396
constexpr uint32_t QUE_FORK_PROCEDURE
Definition: que0que.h:355
constexpr uint32_t QUE_NODE_FUNC
Definition: que0que.h:384
constexpr uint32_t QUE_NODE_ELSIF
Definition: que0que.h:395
constexpr uint32_t QUE_FORK_MYSQL_INTERFACE
Definition: que0que.h:357
constexpr uint32_t QUE_FORK_ACTIVE
Definition: que0que.h:361
ib_mutex_t que_thr_mutex
Mutex protecting the query threads.
que_thr_state_t
Query thread states.
Definition: que0que.h:217
@ QUE_THR_COMMAND_WAIT
Definition: que0que.h:224
@ QUE_THR_RUNNING
Definition: que0que.h:218
@ QUE_THR_SUSPENDED
Definition: que0que.h:226
@ QUE_THR_LOCK_WAIT
Definition: que0que.h:225
@ QUE_THR_COMPLETED
in selects this means that the thread is at the end of its result set (or start, in case of a scroll ...
Definition: que0que.h:223
@ QUE_THR_PROCEDURE_WAIT
Definition: que0que.h:219
static bool thr_is_recv(const que_thr_t *thr)
Determines if this thread is rolling back an incomplete transaction in crash recovery.
constexpr uint32_t QUE_NODE_ORDER
Definition: que0que.h:385
constexpr uint32_t QUE_NODE_INSERT
Definition: que0que.h:371
constexpr uint32_t QUE_FORK_COMMAND_WAIT
Definition: que0que.h:362
constexpr uint32_t QUE_NODE_IF
Definition: que0que.h:387
constexpr uint32_t QUE_FORK_ROLLBACK
Definition: que0que.h:350
constexpr uint32_t QUE_FORK_SELECT_SCROLL
Definition: que0que.h:347
constexpr uint32_t QUE_NODE_OPEN
Definition: que0que.h:391
constexpr uint32_t QUE_NODE_COMMIT
Definition: que0que.h:379
constexpr uint32_t QUE_NODE_LOCK
Definition: que0que.h:370
constexpr uint32_t QUE_NODE_FOR
Definition: que0que.h:393
bool que_thr_stop(que_thr_t *thr)
Stops a query thread if graph or trx is in a state requiring it.
Definition: que0que.cc:594
que_node_t * que_node_get_containing_loop_node(que_node_t *node)
Get the first containing loop node (e.g.
Definition: que0que.cc:764
constexpr uint32_t QUE_FORK_INSERT
Definition: que0que.h:348
que_thr_t * que_fork_scheduler_round_robin(que_fork_t *fork, que_thr_t *thr)
Round robin scheduler.
Definition: que0que.cc:233
que_thr_lock_t
Query thread lock states.
Definition: que0que.h:230
@ QUE_THR_LOCK_NOLOCK
Definition: que0que.h:231
@ QUE_THR_LOCK_TABLE
Definition: que0que.h:233
@ QUE_THR_LOCK_ROW
Definition: que0que.h:232
void que_close(void)
Close the query sub-system.
Definition: que0que.cc:1076
static trx_t * thr_get_trx(que_thr_t *thr)
Gets the trx of a query thread.
static que_node_t * que_fork_get_child(que_fork_t *fork)
Gets the child node of the first thr in a fork.
constexpr uint32_t QUE_NODE_PROC
Definition: que0que.h:386
constexpr uint32_t QUE_NODE_UNDO
Definition: que0que.h:378
que_fork_t * que_fork_create(que_t *graph, que_node_t *parent, ulint fork_type, mem_heap_t *heap)
Creates a query graph fork node.
Definition: que0que.cc:122
static que_node_t * que_node_list_add_last(que_node_t *node_list, que_node_t *node)
Catenates a query graph node to a list of them, possible empty list.
static bool que_graph_is_select(que_t *graph)
Returns true if the query graph is for a SELECT statement.
constexpr uint32_t QUE_NODE_FORK
Definition: que0que.h:376
void que_node_print_info(que_node_t *node)
Prints info of an SQL query graph node.
constexpr uint32_t QUE_NODE_SELECT
Definition: que0que.h:374
que_thr_t * que_thr_end_lock_wait(trx_t *trx)
Moves a suspended query thread to the QUE_THR_RUNNING state and release a worker thread to execute it...
Definition: que0que.cc:191
constexpr uint32_t QUE_NODE_RES_WORD
Definition: que0que.h:383
static void que_node_set_val_buf_size(que_node_t *node, ulint size)
Sets the value buffer size of a graph node.
static void que_node_set_parent(que_node_t *node, que_node_t *parent)
Sets the parent of a graph node.
constexpr uint32_t QUE_NODE_COL_ASSIGNMENT
Definition: que0que.h:392
static que_node_t * que_node_get_parent(que_node_t *node)
Gets the parent node of a query graph node.
constexpr uint32_t QUE_NODE_RETURN
Definition: que0que.h:394
constexpr uint32_t QUE_NODE_THR
Definition: que0que.h:377
constexpr uint32_t QUE_NODE_AGGREGATE
Definition: que0que.h:375
Query graph global types.
void que_node_t
Definition: que0types.h:41
Row operation global types.
Structure for an SQL data field.
Definition: data0data.h:617
Definition: data0type.h:498
The info structure stored at the beginning of a heap block.
Definition: mem0mem.h:302
Extra information supplied for pars_sql().
Definition: pars0pars.h:452
Definition: que0types.h:51
Definition: que0que.h:301
ulint fork_type
fork type
Definition: que0que.h:304
que_common_t common
type: QUE_NODE_FORK
Definition: que0que.h:302
ulint n_active_thrs
if this is the root of a graph, the number query threads that have been started in que_thr_move_to_ru...
Definition: que0que.h:305
ulint state
state of the fork node
Definition: que0que.h:312
que_t * graph
query graph of this node
Definition: que0que.h:303
trx_t * trx
transaction: this is set only in the root node
Definition: que0que.h:310
que_thr_t * caller
pointer to a possible calling query thread
Definition: que0que.h:313
Definition: que0que.h:242
bool is_active
true if the thread has been set to the run state in que_thr_move_to_run_state, but not deactivated in...
Definition: que0que.h:249
que_t * graph
graph where this node belongs
Definition: que0que.h:247
ulint lock_state
lock state of thread (table or row)
Definition: que0que.h:265
row_prebuilt_t * prebuilt
prebuilt structure processed by the query thread
Definition: que0que.h:293
que_node_t * prev_node
pointer to the node from which the control came
Definition: que0que.h:261
struct srv_slot_t * slot
The thread slot in the lock_sys->waiting_threads array protected by lock_sys->wait_mutex when writing...
Definition: que0que.h:277
que_common_t common
type: QUE_NODE_THR
Definition: que0que.h:243
que_node_t * run_node
pointer to the node where the subgraph down from this node is currently executed
Definition: que0que.h:258
que_node_t * child
graph child node
Definition: que0que.h:246
que_thr_state_t state
state of the query thread
Definition: que0que.h:248
ulint magic_n
magic number to catch memory corruption
Definition: que0que.h:244
trx_thrs
lists of threads in wait list of the trx
Definition: que0que.h:285
queue
list of runnable thread nodes in the server task queue
Definition: que0que.h:288
ulint resource
resource usage of the query thread thus far
Definition: que0que.h:263
ulint fk_cascade_depth
maximum cascading call depth supported for foreign key constraint related delete/updates
Definition: que0que.h:290
thrs
list of thread nodes of the fork node
Definition: que0que.h:282
A struct for (sometimes lazily) prebuilt structures in an Innobase table handle used within MySQL; th...
Definition: row0mysql.h:515
Select statement node.
Definition: row0sel.h:329
Thread slot in the thread table.
Definition: srv0srv.h:1227
Symbol table.
Definition: pars0sym.h:203
Definition: trx0trx.h:675
typedef UT_LIST_BASE_NODE_T(rw_lock_t, list) rw_lock_list_t
Version control for database, common definitions, and include files.
unsigned long int ulint
Definition: univ.i:406
Users and sessions global types.
#define UT_LIST_NODE_T(t)
Macro used for legacy reasons.
Definition: ut0lst.h:64