75 typedef std::map<Key, Page>
Pages;
89 typedef std::map<std::string, std::unique_ptr<Sync_point>>
Sync_points;
117 void sync_point(
const std::string &sync_point_name);
120 const std::string &sync_point_name,
121 std::unique_ptr<Sync_point> &&sync_point_handler);
137 lsn_t newest_modification);
140 lsn_t newest_modification);
155extern std::unique_ptr<Log_test>
log_test;
173 const std::string crash_var_name = std::string{
"crash_"} + sync_point_name;
177 log_test->sync_point(sync_point_name);
uint32_t page_no_t
Page number.
Definition: api0api.h:46
Definition: log0test.h:77
virtual ~Sync_point()=default
It is a environment for tests of redo log.
Definition: log0test.h:63
void purge(lsn_t max_dirty_page_age)
Definition: log0test.cc:76
const Pages & flushed() const
Definition: log0test.cc:242
std::mutex m_purge_mutex
Definition: log0test.h:143
std::map< Key, Page > Pages
Definition: log0test.h:75
int verbosity() const
Definition: log0test.cc:278
void sync_point(const std::string &sync_point_name)
Definition: log0test.cc:246
void set_verbosity(int level)
Definition: log0test.cc:280
void recovered_add(Key key, Value value, lsn_t oldest_modification, lsn_t newest_modification)
Definition: log0test.cc:230
uint64_t m_options_enabled
Definition: log0test.h:149
Pages m_flushed
Definition: log0test.h:146
void fsync_written_pages()
Definition: log0test.cc:66
void register_sync_point_handler(const std::string &sync_point_name, std::unique_ptr< Sync_point > &&sync_point_handler)
Definition: log0test.cc:256
Pages m_recovered
Definition: log0test.h:147
void set_enabled(Options option, bool enabled)
Definition: log0test.cc:266
Pages m_written
Definition: log0test.h:145
int flush_every() const
Definition: log0test.cc:274
std::mutex m_mutex
Definition: log0test.h:142
void recovered_reset(Key key, lsn_t oldest_modification, lsn_t newest_modification)
Definition: log0test.cc:219
static byte * create_mlog_rec(byte *rec, Key key, Value value, size_t payload)
Definition: log0test.cc:123
std::map< lsn_t, Page > m_buf
Definition: log0test.h:144
int m_flush_every
Definition: log0test.h:151
bool enabled(Options option) const
Definition: log0test.cc:262
const Pages & recovered() const
Definition: log0test.cc:244
Sync_points m_sync_points
Definition: log0test.h:148
int64_t Value
Definition: log0test.h:66
static const byte * parse_mlog_rec(const byte *begin, const byte *end, Key &key, Value &value, lsn_t &start_lsn, lsn_t &end_lsn)
Definition: log0test.cc:162
int m_verbosity
Definition: log0test.h:150
void add_dirty_page(const Page &page)
Definition: log0test.cc:55
void set_flush_every(int flush_every)
Definition: log0test.cc:276
Options
Definition: log0test.h:84
@ VALIDATE_RECENT_WRITTEN
lsn_t oldest_modification_approx() const
Calculates oldest_modification of the earliest added dirty page during the test in log0log-t.
Definition: log0test.cc:49
std::map< std::string, std::unique_ptr< Sync_point > > Sync_points
Definition: log0test.h:89
page_no_t Key
Definition: log0test.h:65
int page
Definition: ctype-mb.cc:1224
std::unique_ptr< Log_test > log_test
Represents currently running test of redo log, nullptr otherwise.
Definition: log0test.cc:47
static void log_sync_point(const char(&sync_point_name)[N])
This function is responsible for three actions:
Definition: log0test.h:170
uint64_t lsn_t
Type used for all log sequence number storage and arithmetic.
Definition: log0types.h:63
#define DBUG_EXECUTE_IF(keyword, a1)
Definition: my_dbug.h:171
#define DBUG_SUICIDE()
Definition: my_dbug.h:228
Common header for many mysys elements.
std::atomic< Type > N
Definition: ut0counter.h:225
const char * begin(const char *const c)
Definition: base64.h:44
Cursor end()
A past-the-end Cursor.
Definition: rules_table_service.cc:192
required string key
Definition: replication_asynchronous_connection_failover.proto:60
Declarations for the Debug Sync Facility.
#define CONDITIONAL_SYNC_POINT(NAME)
Definition: debug_sync.h:129
Definition: log0test.h:68
lsn_t oldest_modification
Definition: log0test.h:71
Key key
Definition: log0test.h:69
Value value
Definition: log0test.h:70
lsn_t newest_modification
Definition: log0test.h:72