diff options
| author | Stefan Boberg <[email protected]> | 2023-05-16 21:35:39 +0200 |
|---|---|---|
| committer | GitHub <[email protected]> | 2023-05-16 21:35:39 +0200 |
| commit | 81b2757f917e34bb338fad7965ae8a74e160bee4 (patch) | |
| tree | 931ba100471a2369c62a6e41a1b4a7937ed31f6f /src/zenstore/cas.cpp | |
| parent | added benchmark utility command `bench` (#298) (diff) | |
| download | zen-81b2757f917e34bb338fad7965ae8a74e160bee4.tar.xz zen-81b2757f917e34bb338fad7965ae8a74e160bee4.zip | |
Content scrubbing (#271)
Added zen scrub command which may be triggered via the zen CLI helper. This traverses storage and validates contents either by content hash and/or by structure. If unexpected data is encountered it is invalidated.
Diffstat (limited to 'src/zenstore/cas.cpp')
| -rw-r--r-- | src/zenstore/cas.cpp | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/zenstore/cas.cpp b/src/zenstore/cas.cpp index ab05e3e7c..b98f01385 100644 --- a/src/zenstore/cas.cpp +++ b/src/zenstore/cas.cpp @@ -18,6 +18,7 @@ #include <zencore/thread.h> #include <zencore/trace.h> #include <zencore/uid.h> +#include <zencore/workthreadpool.h> #include <zenstore/cidstore.h> #include <zenstore/gc.h> #include <zenstore/scrubcontext.h> @@ -74,6 +75,8 @@ private: void UpdateManifest(); }; +////////////////////////////////////////////////////////////////////////// + CasImpl::CasImpl(GcManager& Gc) : m_TinyStrategy(Gc), m_SmallStrategy(Gc), m_LargeStrategy(Gc) { } @@ -323,7 +326,8 @@ TEST_CASE("CasStore") std::unique_ptr<CasStore> Store = CreateCasStore(Gc); Store->Initialize(config); - ScrubContext Ctx; + WorkerThreadPool ThreadPool{1}; + ScrubContext Ctx{ThreadPool}; Store->ScrubStorage(Ctx); IoBuffer Value1{16}; |