Generate logical timestamps for MTS using WRITESET in the binlog-transaction-dependency-tracking option.
More...
#include <rpl_trx_tracking.h>
Generate logical timestamps for MTS using WRITESET in the binlog-transaction-dependency-tracking option.
◆ Writeset_history
◆ Writeset_trx_dependency_tracker()
Writeset_trx_dependency_tracker::Writeset_trx_dependency_tracker |
( |
ulong |
max_history_size | ) |
|
|
inline |
◆ get_dependency()
void Writeset_trx_dependency_tracker::get_dependency |
( |
THD * |
thd, |
|
|
int64 & |
sequence_number, |
|
|
int64 & |
commit_parent |
|
) |
| |
Main function that gets the dependencies using the WRITESET tracker.
Get the writeset dependencies of a transaction.
- Parameters
-
[in] | thd | THD of the caller. |
[in,out] | sequence_number | sequence_number initialized and returned. |
[in,out] | commit_parent | commit_parent to be returned. |
This takes the commit_parent that must be previously set using Commit_order_trx_dependency_tracker and tries to make the commit_parent as low as possible, using the writesets of each transaction. The commit_parent returned depends on how many row hashes are stored in the writeset_history, which is cleared once it reaches the user-defined maximum.
- Parameters
-
[in] | thd | Current THD from which to extract trx context. |
[in,out] | sequence_number | Sequence number of current transaction. |
[in,out] | commit_parent | Commit_parent of current transaction, pre-filled with the commit_parent calculated by Commit_order_trx_dependency_tracker to use when the writeset commit_parent is not valid. |
◆ rotate()
void Writeset_trx_dependency_tracker::rotate |
( |
int64 |
start | ) |
|
◆ m_opt_max_history_size
std::atomic<ulong> Writeset_trx_dependency_tracker::m_opt_max_history_size |
◆ m_writeset_history
◆ m_writeset_history_start
int64 Writeset_trx_dependency_tracker::m_writeset_history_start |
|
private |
The documentation for this class was generated from the following files: