mirror of
https://github.com/kvcache-ai/AgentENV.git
synced 2026-11-05 01:17:36 +00:00
[PR #185] [MERGED] fix(snapshot): revert digest tracking on compaction output paths #234
Labels
No labels
bug
documentation
enhancement
enhancement
pull-request
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
kvcache-ai/AgentENV#234
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
📋 Pull Request Information
Original PR: https://github.com/kvcache-ai/AgentENV/pull/185
Author: @huajq
Created: 8/18/2026
Status: ✅ Merged
Merged: 8/18/2026
Merged by: @yingdi-shan
Base:
main← Head:fix/snapshot-compaction-digest-revert📝 Commits (1)
ecdd8a9fix(snapshot): revert digest tracking on compaction output paths📊 Changes
6 files changed (+23 additions, -231 deletions)
View changed files
📝
src/sandbox/firecracker/overlaybd_snapshot.rs(+10 -17)📝
src/sandbox/firecracker/sandbox.rs(+2 -3)📝
src/sandbox/ublk/mod.rs(+1 -1)📝
src/sandbox/ublk/overlaybd.rs(+10 -37)➖
storage/overlaybd/src/lsmt/file/digest_tracking.rs(+0 -171)📝
storage/overlaybd/src/lsmt/file/mod.rs(+0 -2)📄 Description
What
Revert the digest-tracking half of
5afd9d1(PR #177):compact_layersandpublish_memory_overlaybd_layergo back to plaincreate_commit_args, andDigestTrackingFile/OrderedWriterare removed. The OSS multipart upload parallelization from the same commit (64 MiB parts × 8 concurrent uploads) is kept — it is unrelated to the regression.Why
5afd9d1wrapped everycompact_tooutput inDigestTrackingFile+OrderedWriterso OSS/ACR publish could skip re-hashing sealed layers. On all snapshot packing paths this:The produced descriptor is only consumed by the OSS repository backend, the ACR source-registry publisher, and (opportunistically) P2P content-addressed layer advertisement.
posix_fsand local-only snapshots pay the cost with zero benefit. Even for OSS the trade is negative in the standard flow: publish runs in the same synchronous request as capture with a warm page cache, so the saved re-read costs nothing while the serial-write penalty is real; inherited layers already carry descriptors from the parent manifest via OSS runtime resolution, so there is no per-publish re-hash multiplier either. On aarch64 hosts without SHA-256 hardware acceleration the added snapshot-creation latency is significant (#184).Related issue
Closes #184
Scope and non-goals
compact_layers,publish_memory_overlaybd_layer,build_mem_snapshot_image_configand their callers) and removal ofDigestTrackingFile/OrderedWriter.5afd9d1(kept). No changes to publish-side consumers — they already handle descriptorless layers.Design and behavior changes
Snapshot packing returns to pre-5afd9d1 behavior: raw-mode compaction writes run at full concurrency (32) and no content digest is computed during capture. Layers staged without descriptors flow through the existing publish fallbacks: OSS
import_managed_layer_by_hash(or dense export for sparse layers), ACR raw/dense fallback, P2P uuid-keyed layer artifacts. Theclose_seal + restackdescriptor path (ublk-daemon / image layer) is pre-existing and untouched.Compatibility and operations
image.jsonlowers no longer carry digest/size for newly compacted layers; all consumers already accept descriptorless layers (this was the pre-5afd9d1 format).Validation
make fmt(cargo fmt --all -- --check)make clippy(cargo clippy -p agentenv -p overlaybd --all-targets -- -D warnings)make test-unitmake -C services test(required whenservices/changes)maketargetCommands and results:
Skipped checks and reasons:
make -C services test:services/untouched.Risks and reviewer notes
src/sandbox/ublk/overlaybd.rsandsrc/sandbox/firecracker/overlaybd_snapshot.rs— confirm the revert is faithful andsrc/snapshot/repository/backends/oss/client.rsis untouched.Checklist
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.