24#ifndef MYSQL_SCHEDULER_TRANSACTION_ORDER_SCHEDULE_H
25#define MYSQL_SCHEDULER_TRANSACTION_ORDER_SCHEDULE_H
54 uint64_t commit_time);
79 unsigned int phase_id)
const override;
Represents the identifier of a task ingested by the scheduler,.
Definition: task_id.h:41
Represents task schedule.
Definition: task_schedule.h:45
Represents schedule for a transaction executing in two phases: apply and committing,...
Definition: transaction_order_schedule.h:41
Transaction_order_schedule(Task_id task_id, Scheduler_clock_ptr trx_clock, uint64_t trx_time, Scheduler_clock_ptr commit_clock, uint64_t commit_time)
Constructor.
Definition: transaction_order_schedule.cpp:31
Scheduler_clock_ptr m_trx_clock
Clock whole task schedule is based on.
Definition: transaction_order_schedule.h:90
Scheduler_clock_ptr m_commit_clock
Commit clock, dependency clock for commit phase.
Definition: transaction_order_schedule.h:94
const Time_delay_type & get_task_delay() const override
Gets information about next execution time.
Definition: transaction_order_schedule.cpp:55
bool next() override
This function modifies the state of the schedule to next state.
Definition: transaction_order_schedule.cpp:47
unsigned int m_phase
Current schedule phase.
Definition: transaction_order_schedule.h:98
bool is_finished() const override
Definition: transaction_order_schedule.cpp:40
uint64_t m_commit_time
Transaction commit start time, relative to the commit clock.
Definition: transaction_order_schedule.h:96
Phase
Definition: transaction_order_schedule.h:43
const Time_delay_type & get_phase_delay(unsigned int phase_id) const override
Gets information about execution time in specific phase.
Definition: transaction_order_schedule.cpp:65
Task_id m_task_id
This task id.
Definition: transaction_order_schedule.h:88
unsigned int get_phase_id() const override
Returns current phase id (sequence number)
Definition: transaction_order_schedule.cpp:81
const Scheduler_clock_ptr & get_clock() const override
Obtain task clock.
Definition: transaction_order_schedule.cpp:59
uint64_t m_trx_time
Transaction start execution time, relative to the m_trx_clock.
Definition: transaction_order_schedule.h:92
const Task_id & get_id() const override
Obtain task id.
Definition: transaction_order_schedule.cpp:63
const Scheduler_clock_ptr & get_phase_clock(unsigned int phase_id) const override
Obtain task clock for the given phase id.
Definition: transaction_order_schedule.cpp:73
Definition: base_dependency_tracker.h:41
std::uint64_t Time_delay_type
Time points are created as a delay from a specific start time (clock relative measure)
Definition: time.h:39
std::shared_ptr< Scheduler_clock > Scheduler_clock_ptr
Definition: scheduler_clock.h:36