Document communication between metadata server and clients in the misc/PROTOCOL.txt file and add generation counters for files

This commit is contained in:
2025-11-24 13:04:29 +01:00
parent 1c768bb8f1
commit 49091aff6d
7 changed files with 445 additions and 98 deletions
+10 -4
View File
@@ -12,10 +12,16 @@ typedef struct {
int entry_limit;
} WAL;
int wal_open(WAL *wal, FileTree *file_tree, string file_path, int entry_limit);
int wal_open(WAL *wal, FileTree *file_tree, string file_path, int entry_limit);
void wal_close(WAL *wal);
int wal_append_create(WAL *wal, string path, bool is_dir, uint64_t chunk_size);
int wal_append_delete(WAL *wal, string path);
int wal_append_write(WAL *wal, string path, uint64_t off, uint64_t len, uint32_t num_chunks, uint32_t chunk_size, SHA256 *prev_hashes, SHA256 *hashes);
int wal_append_create(WAL *wal, string path, bool is_dir, uint64_t chunk_size);
int wal_append_delete(WAL *wal, string path, uint64_t expect_gen);
int wal_append_write(WAL *wal, string path, uint64_t off,
uint64_t len, uint32_t num_chunks, uint64_t expect_gen,
SHA256 *hashes);
#endif // WAL_INCLUDED