mariadb/storage/maria/ma_checkpoint.h
unknown a1f25544d5 WL#3234 "Maria - control file manager"
- fixes to the control file module
- unit test for it
- renames of all Maria files I created to start with ma_


storage/maria/ma_checkpoint.c:
  Rename: storage/maria/checkpoint.c -> storage/maria/ma_checkpoint.c
storage/maria/ma_checkpoint.h:
  Rename: storage/maria/checkpoint.h -> storage/maria/ma_checkpoint.h
storage/maria/ma_least_recently_dirtied.c:
  Rename: storage/maria/least_recently_dirtied.c -> storage/maria/ma_least_recently_dirtied.c
storage/maria/ma_least_recently_dirtied.h:
  Rename: storage/maria/least_recently_dirtied.h -> storage/maria/ma_least_recently_dirtied.h
storage/maria/ma_recovery.c:
  Rename: storage/maria/recovery.c -> storage/maria/ma_recovery.c
storage/maria/ma_recovery.h:
  Rename: storage/maria/recovery.h -> storage/maria/ma_recovery.h
storage/maria/Makefile.am:
  control file module and its unit test program
storage/maria/ma_control_file.c:
  DBUG_ tags. Fix for gcc warnings.
  log_no -> logno (I felt "_no" sounded like a standalone "No" word).
  ma_ prefix for some functions.
  last_checkpoint_lsn_at_startup -> last_checkpoint_lsn (no need
  to make special vars for the values at startup). Same for last_logno.
  ma_control_file_write_and_force() now updates last_checkpoint_lsn
  and last_logno, the idea being that they belong to the module,
  others should not update them.
  And thus when the module shuts down, it zeroes those vars.
storage/maria/ma_control_file.h:
  importing structs from Sanja to get the control file module to compile;
  we'll remove that when Sanja pushes the log handler.
  CONTROL_FILE_IMPOSSIBLE_LOGNO is 0, not FFFFFFFF.
storage/maria/ma_control_file_test.c:
  Unit test program for the Maria control file module.
  Modelled after other ma_test* files in this directory (so, does
  not follow the unit test framework recently introduced with libtap;
  TODO as a task on all ma_test* programs).
  We test that writing to the control file works, and re-reading from it
  too, we check (by reading the file by ourselves) that its content
  on disk is correct, and check that a corrupted control file is detected.
2006-09-01 17:53:10 +02:00

19 lines
655 B
C

/*
WL#3071 Maria checkpoint
First version written by Guilhem Bichot on 2006-04-27.
Does not compile yet.
*/
/* This is the interface of this module. */
typedef enum enum_checkpoint_level {
NONE=-1,
INDIRECT, /* just write dirty_pages, transactions table and sync files */
MEDIUM, /* also flush all dirty pages which were already dirty at prev checkpoint*/
FULL /* also flush all dirty pages */
} CHECKPOINT_LEVEL;
void request_asynchronous_checkpoint(CHECKPOINT_LEVEL level);
my_bool execute_synchronous_checkpoint(CHECKPOINT_LEVEL level);
my_bool execute_asynchronous_checkpoint_if_any();
/* that's all that's needed in the interface */