diff options
| author | Dan Engelbrecht <[email protected]> | 2024-11-15 10:06:39 +0100 |
|---|---|---|
| committer | GitHub Enterprise <[email protected]> | 2024-11-15 10:06:39 +0100 |
| commit | aca6f56fde841454b13ed18136008b0ffe946aed (patch) | |
| tree | 3770efa6c789b45de8ea3ec426da7a77e7813775 /src/zen/cmds/admin_cmd.cpp | |
| parent | fixed some issues with ZenServerInstance::SpawnServer (#218) (diff) | |
| download | archived-zen-aca6f56fde841454b13ed18136008b0ffe946aed.tar.xz archived-zen-aca6f56fde841454b13ed18136008b0ffe946aed.zip | |
oplog prep gc fix (#216)
- Added option gc-validation to zenserver that does a check for missing references in all oplog post full GC. Enabled by default.
- Feature: Added option gc-validation to zen gc command to control reference validation. Enabled by default.
- Added more details in post GC log.
- Fixed race condition in oplog writes which could cause used attachments to be incorrectly removed by GC
Diffstat (limited to 'src/zen/cmds/admin_cmd.cpp')
| -rw-r--r-- | src/zen/cmds/admin_cmd.cpp | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/src/zen/cmds/admin_cmd.cpp b/src/zen/cmds/admin_cmd.cpp index 3b24b9078..e07e28f54 100644 --- a/src/zen/cmds/admin_cmd.cpp +++ b/src/zen/cmds/admin_cmd.cpp @@ -149,6 +149,13 @@ GcCommand::GcCommand() "Enable storing attachments referenced by project oplogs in meta data", cxxopts::value(m_StoreProjectAttachmentMetaData)->default_value("false"), "<project-attachments-store>"); + + m_Options.add_option("", + "", + "gc-validation", + "Enable validation of references after full GC.", + cxxopts::value(m_EnableValidation)->default_value("true"), + "<cache-attachments-store>"); } GcCommand::~GcCommand() @@ -237,6 +244,7 @@ GcCommand::Run(const ZenCliOptions& GlobalOptions, int argc, char** argv) { Params.Add({"storeprojectattachmentmetadata", m_StoreProjectAttachmentMetaData ? "true" : "false"}); } + Params.Add({"enablevalidation", m_EnableValidation ? "true" : "false"}); cpr::Session Session; Session.SetHeader(cpr::Header{{"Accept", "application/json"}}); |