JudgeChecks (directory): drop the CreateDirectory the commit lease already makes; tests for a never-written non-home store and for a check-less batch beside a held lock

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
Meta Vens 2026-10-14 02:23:14 +02:00
commit 696a712088
2 changed files with 37 additions and 1 deletions

View file

@ -272,7 +272,6 @@ public sealed class DirectoryMessagePackBackingStore : CacheBackingStore
return base.JudgeChecks(keys, wait);
return Held(() =>
{
Directory.CreateDirectory(_manifestFile.DirectoryName!);
using var commitLease = AcquireCommitLease(wait, create: true);
if (commitLease == null)
return CultCommitOutcome.Contended;