e2e: fix EROFS layer push idempotency on unpublish retry and enhance diagnostic logs #134
All Vouch review confidence checks passed
Residual risk 0.14 = Change Risk (0.37) × (1 − Review Confidence (0.60)).
Review depth and reviewer attention state are adequate.
Model 1 · Change Risk (XGBoost)
Score: 0.37 · 219 lines diff across 2 files
Model 2 · Review Depth (DistilBERT)
Depth Score: 0.17 · 1 substantive comment(s)
Model 3 · Review Timing & Attention
Session adequacy: 100% · Reviewer familiarity: 35%
Bedrock Claude 3 · Risk Narration
(disconnected)
Groq Risk Narration
AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
Model 1 · Change Risk Attribution
SHAP Weights
Diff Size
diff_size
0.323
Shallow Review Depth
shallow_review_depth
0.289
Real PR Conversation Timeline
1 comments
"Review active on #134"
general
weight: 0.35
justinsb
Fixes #133
Summary of Changes
1. Diagnostic Dump Fix (
tests/e2e/harness.go):- Enhanced
DumpDiagnosticLogsto query pod listings in the target namespace with wide output, capture container logs for each daemonset pod (bothagentfs-node-daemonandnode-driver-registrar), inspect--previouscontainer logs to reveal crash/restart causes, and describe active/terminating test pods.2. Idempotent Layer Push & Concurrency Fix (
cmd/agentfs-node-daemon/main.go):- Fixed
pushErofsLayersSnapshotto check if the controller already contains the target layer stack before reporting an optimistic concurrency conflict. This prevents unpublish retries from getting stuck in an infinite conflict loop if the server snapshot was updated on a previous try before an unmount error/retry.- Handled missing local
snapshot.pbgracefully on disk without throwing fatal read errors.- Updated
snapshot.pbon disk immediately after snapshot upload to keep local state synchronized with the controller.- Persisted
volume_idto the local volume directory so logical volume mappings survive daemon restarts, and delayedvolumeMappingsdeletion until after unpublish and cleanup succeed.- Returned errors from
pullSnapshotinNodePublishVolumeinstead of continuing with an unpopulated volume.- Added
MNT_DETACHfallback fortargetPath,lowerPath, and layer mounts if standard unmount returnsEBUSY.3. E2E Test Robustness (
tests/e2e/e2e_test.go):- Added
terminationGracePeriodSeconds: 1on layer test pods to prevent 30-second shutdown delays during pod deletion.- Added
waitForSnapshotLayershelper that waits for the snapshot to appear on the controller with the expected layer count.