aboutsummaryrefslogtreecommitdiff
path: root/src/zenstore/projectstore.cpp
diff options
context:
space:
mode:
authorDan Engelbrecht <[email protected]>2026-02-03 16:31:40 +0100
committerGitHub Enterprise <[email protected]>2026-02-03 16:31:40 +0100
commit932b15e7318ed65973373aa3c4a94714cd688d7b (patch)
treefce75256111f07469cd34b2381b89aa9a0a491b7 /src/zenstore/projectstore.cpp
parentadd command line option for scrub timeslice (#742) (diff)
downloadzen-932b15e7318ed65973373aa3c4a94714cd688d7b.tar.xz
zen-932b15e7318ed65973373aa3c4a94714cd688d7b.zip
reduce blocking in scrub (#743)
* reduce held locks while performing scrub operation
Diffstat (limited to 'src/zenstore/projectstore.cpp')
-rw-r--r--src/zenstore/projectstore.cpp2
1 files changed, 2 insertions, 0 deletions
diff --git a/src/zenstore/projectstore.cpp b/src/zenstore/projectstore.cpp
index c5b27c1ea..e6c8d624a 100644
--- a/src/zenstore/projectstore.cpp
+++ b/src/zenstore/projectstore.cpp
@@ -3932,6 +3932,7 @@ ProjectStore::Project::Scrub(ScrubContext& Ctx)
{
for (const std::string& OpLogId : OpLogs)
{
+ Ctx.ThrowIfDeadlineExpired();
Ref<ProjectStore::Oplog> OpLog;
{
if (auto OpIt = m_Oplogs.find(OpLogId); OpIt != m_Oplogs.end())
@@ -4358,6 +4359,7 @@ ProjectStore::ScrubStorage(ScrubContext& Ctx)
}
for (const Ref<Project>& Project : Projects)
{
+ Ctx.ThrowIfDeadlineExpired();
Project->Scrub(Ctx);
}
}