MySQL 8.4.2
Source Code Documentation
Parallel_reader::Thread_ctx Struct Reference

Thread related context information. More...

#include <row0pread.h>

Public Member Functions

 Thread_ctx (size_t id) noexcept
 Constructor. More...
 
 ~Thread_ctx () noexcept
 Destructor. More...
 
template<typename T >
void set_callback_ctx (T *ctx) noexcept
 Set thread related callback information. More...
 
template<typename T >
T * get_callback_ctx () noexcept
 Get the thread related callback information/. More...
 
void create_blob_heap () noexcept
 Create BLOB heap. More...
 
State get_state () const noexcept
 
void savepoint () noexcept
 Save current position, commit any active mtr. More...
 
dberr_t restore_from_savepoint () noexcept
 Restore saved position and resume scan. More...
 
 Thread_ctx (Thread_ctx &&)=delete
 
 Thread_ctx (const Thread_ctx &)=delete
 
Thread_ctxoperator= (Thread_ctx &&)=delete
 
Thread_ctxoperator= (const Thread_ctx &)=delete
 

Public Attributes

size_t m_thread_id {std::numeric_limits<size_t>::max()}
 Thread ID. More...
 
void * m_callback_ctx {}
 Callback information related to the thread. More...
 
mem_heap_tm_blob_heap {}
 BLOB heap per thread. More...
 
State m_state {State::UNKNOWN}
 Worker thread state. More...
 
PCursorm_pcursor {}
 Current persistent cursor. More...
 

Detailed Description

Thread related context information.

Constructor & Destructor Documentation

◆ Thread_ctx() [1/3]

Parallel_reader::Thread_ctx::Thread_ctx ( size_t  id)
inlineexplicitnoexcept

Constructor.

Parameters
[in]idThread ID

◆ ~Thread_ctx()

Parallel_reader::Thread_ctx::~Thread_ctx ( )
inlinenoexcept

Destructor.

◆ Thread_ctx() [2/3]

Parallel_reader::Thread_ctx::Thread_ctx ( Thread_ctx &&  )
delete

◆ Thread_ctx() [3/3]

Parallel_reader::Thread_ctx::Thread_ctx ( const Thread_ctx )
delete

Member Function Documentation

◆ create_blob_heap()

void Parallel_reader::Thread_ctx::create_blob_heap ( )
inlinenoexcept

Create BLOB heap.

◆ get_callback_ctx()

template<typename T >
T * Parallel_reader::Thread_ctx::get_callback_ctx ( )
inlinenoexcept

Get the thread related callback information/.

Returns
return context.

◆ get_state()

State Parallel_reader::Thread_ctx::get_state ( ) const
inlinenoexcept
Returns
the worker thread state.

◆ operator=() [1/2]

Thread_ctx & Parallel_reader::Thread_ctx::operator= ( const Thread_ctx )
delete

◆ operator=() [2/2]

Thread_ctx & Parallel_reader::Thread_ctx::operator= ( Thread_ctx &&  )
delete

◆ restore_from_savepoint()

dberr_t Parallel_reader::Thread_ctx::restore_from_savepoint ( )
noexcept

Restore saved position and resume scan.

Returns
DB_SUCCESS or error code.

◆ savepoint()

void Parallel_reader::Thread_ctx::savepoint ( )
noexcept

Save current position, commit any active mtr.

◆ set_callback_ctx()

template<typename T >
void Parallel_reader::Thread_ctx::set_callback_ctx ( T *  ctx)
inlinenoexcept

Set thread related callback information.

Parameters
[in]ctxcallback context

Member Data Documentation

◆ m_blob_heap

mem_heap_t* Parallel_reader::Thread_ctx::m_blob_heap {}

BLOB heap per thread.

◆ m_callback_ctx

void* Parallel_reader::Thread_ctx::m_callback_ctx {}

Callback information related to the thread.

Note
Needs to be created and destroyed by the callback itself.

◆ m_pcursor

PCursor* Parallel_reader::Thread_ctx::m_pcursor {}

Current persistent cursor.

◆ m_state

State Parallel_reader::Thread_ctx::m_state {State::UNKNOWN}

Worker thread state.

◆ m_thread_id

size_t Parallel_reader::Thread_ctx::m_thread_id {std::numeric_limits<size_t>::max()}

Thread ID.


The documentation for this struct was generated from the following files: