落盘机制修改

This commit is contained in:
2026-03-06 11:54:30 +00:00
parent c4e9bedd0a
commit 2e6baf0efe
14 changed files with 1302 additions and 443 deletions

View File

@@ -20,6 +20,11 @@ typedef enum {
PERSIST_NONE
} PersistenceType;
typedef enum {
OPLOG_SYNC_NONE,
OPLOG_SYNC_EVERY_SEC
} OplogSyncMode;
typedef enum {
REPLICA_DISABLE,
REPLICA_ENABLE
@@ -53,6 +58,7 @@ typedef struct {
char array_file[256];
char rbtree_file[256];
char hash_file[256];
OplogSyncMode oplog_sync_mode;
AllocatorType allocator;
MemLeakDetectMode leak_mode;
@@ -68,6 +74,7 @@ int config_load(const char *filename, AppConfig *out_cfg);
const char *log_level_to_string(LogLevel lvl);
const char *server_mode_to_string(ServerMode mode);
const char *persistence_to_string(PersistenceType p);
const char *oplog_sync_mode_to_string(OplogSyncMode m);
const char *allocator_to_string(AllocatorType a);
const char *leakage_to_string(MemLeakDetectMode a);
const char *replica_to_string(ReplicaMode a);