mirror of
https://github.com/kvcache-ai/AgentENV.git
synced 2026-11-05 01:17:36 +00:00
[PR #270] [MERGED] fix(p2p): avoid duplicate storage of fetched image layers #306
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#306
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/270
Author: @LSX-s-Software
Created: 9/9/2026
Status: ✅ Merged
Merged: 9/10/2026
Merged by: @yingdi-shan
Base:
main← Head:perf/p2p📝 Commits (2)
1118782fix(p2p): avoid duplicate storage of fetched image layers953f56bfix(p2p): fix race condition between download and export📊 Changes
6 files changed (+287 additions, -53 deletions)
View changed files
📝
src/image/cache/service.rs(+15 -13)📝
src/p2p/iroh/transport.rs(+209 -29)📝
src/p2p/mock.rs(+9 -4)📝
src/p2p/mod.rs(+1 -1)📝
src/p2p/transport.rs(+40 -6)📝
src/p2p/types.rs(+13 -0)📄 Description
What
Skip automatic P2P advertisement when fetching converted image layers. After validation, publish the persisted image-cache file through the existing
Referencepath so the fetched blob is not retained as a second advertised artifact.Why
The current code stores two copies of the converted image layer: one in P2P's internal blob store and the other in the image cache. This duplication of storage takes up twice as much space.
Scope and non-goals
Scope:
Non-Goals:
Validation
make fmtmake clippymake test-unitmake -C services test(required whenservices/changes)maketargetChecklist
🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.