26#ifndef MYSQL_CSA_SESSION_GUARD_H
27#define MYSQL_CSA_SESSION_GUARD_H
For each client connection we create a separate thread with THD serving as a thread/connection descri...
Definition: sql_lexer_thd.h:36
thread_local THD * current_thd
Definition: current_thd.cc:26
Definition: channel.cpp:28
RAII guard for temporarily switching current_thd to a session THD.
Definition: session_guard.h:33
THD * m_orig_thd
Definition: session_guard.h:44
Session_guard(THD *thd)
Constructor: saves original current_thd and sets to the given thd.
Definition: session_guard.h:35
~Session_guard()
Destructor: restores the original current_thd.
Definition: session_guard.h:41