Repository navigation
ci: store each app-host product file once in the product archive - #14601
Conversation
|
Navigate logical layers of code changes, visualize relationships, and explore their blast radius. No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository: manaflow-ai/cmux/.coderabbit.yaml Review profile: ASSERTIVE Plan: Advanced Run ID: 📒 Files selected for processing (3)
Included review availability: Your plan provides up to 10 included reviews per hour; 0 remain after this review. 📝 WalkthroughWalkthroughThe macOS, seed-derived-data, and end-to-end workflows now stage build products with symlinks followed and files hard-linked before archiving the staged tree. The macOS workflow retains ChangesProduct Archive Packaging
Priority: ➖ Normal Estimated code review effort: 2 (Simple) | ~12 minutes Change: Refactor Merge Risk: ⚪ Minimal · up to The changed archives remain compatible with the supplied product-reuse path. No identified issue blocks merging after normal checks. Architecture SummaryArchitecture risk: 🔵 Low · up to The changed surface does not map to a changed system, dependency edge, entrypoint, or external dependency. Changed systems: None identified. Architecture concerns Review detailsBefore / after behavior
🚥 Pre-merge checks | ✅ 25✅ Passed checks (25 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
All contributors have signed the CLA ✍️ ✅ |
Build/Products reaches every framework binary through Versions/Current symlinks. Product extractors accept no symlinks, so packaging used `tar -h`, which stored each framework binary three times: 1.9 GB on disk became 2.7 GB of tar and 830 MB gzipped. On an owned Mac the upload runs at about 7.5 MB/s (a per-host uplink cap), so the duplicates cost about 35 s of every compile admission and as much again on every owned consumer download. Stage the tree as hard links with the symlinks followed (pax -rwlL, the same tree `tar -h` wrote) beside the DerivedData, and tar the stage. tar stores each file once and the other paths as hard links, which tar -x, aa and reuse_app_host_products.py all extract to the same files. Measured on a kept cmux10s product: 830 MB -> 572 MB, 41 s -> 28 s to pack. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
d6cd796 to
7a2870f
Compare
|
Merge receipt for |
c055747 ci: parse runner expressions in the fork guard, and gate LINUX_RUNNER on fork PRs (manaflow-ai#14192) fc112a8 docs(testing): describe how run-e2e.sh actually picks the runner (manaflow-ai#14620) 0f6edfa ci(owned): keep seeds until the disk is actually short, not at a fixed 6 (manaflow-ai#14621) 1b78097 CI: one owned-pool rescue sweeper instead of a rescue run per CI run (manaflow-ai#14602) c7e79f6 Hold Files tree reloads while its context menu is open (manaflow-ai#14451) dbb24cb ci: read the owned-pool rescue's Actions API through the route App (manaflow-ai#14499) 36b8063 ci: store each app-host product file once in the product archive (manaflow-ai#14601) 0dba677 CI: run CmuxWorkspaces package tests (manaflow-ai#14592) 2244e98 Fix color detection in native tmux mirrors (manaflow-ai#14175) 3d2478e build: keep every built file in a project group so Xcode reuses its build description (manaflow-ai#14486) a1a5ae9 ci(cmux-tui): cache cargo builds in the Rust jobs (manaflow-ai#14613) 560e640 ci(owned): keep 8 seeds per mini and pick seeds by cost, not a 2-commit cap (manaflow-ai#14607) 561d317 cmux-debug-cli: find a publish-hq build in the HQ tag app cache (manaflow-ai#14579) c0aaac7 fix(events): survive receive-timeout reconfiguration churn during replay (manaflow-ai#13888) 3bd994a fix: keep split zoom when the zoomed pane outlives a tab close (manaflow-ai#12853) ca984c7 Session snapshots can send binding actions to ghostty on a surface that is no longer live (manaflow-ai#12623) a47d65b settings: expose local tmux session persistence (manaflow-ai#13210) e3acb25 ci: give an owned Mac's full app rebuild 35 minutes to compile (manaflow-ai#14594) # Conflicts: # .github/workflows/ci-artifact-transport.yml # .github/workflows/ci-cache-receipts.yml # .github/workflows/ci-guards.yml # .github/workflows/ci-macos.yml # .github/workflows/ci-owned-pool-rescue.yml # .github/workflows/ci-web.yml # .github/workflows/ci.yml # .github/workflows/cloud-machine-tests.yml # .github/workflows/cloud-vm-guest-install.yml # .github/workflows/cloud-vm-image-contract.yml # .github/workflows/cloud-vm-image-reachability.yml # .github/workflows/cloudflare-relay.yml # .github/workflows/cmux-skill-contract.yml # .github/workflows/cmux-tui-sdks.yml # .github/workflows/cmux-tui-spec.yml # .github/workflows/cmux-tui.yml # .github/workflows/indexnow-tests.yml # .github/workflows/iroh-v2.yml # .github/workflows/localization-catalog.yml # .github/workflows/r2-upload-tests.yml # .github/workflows/remote-daemon.yml # .github/workflows/repair-nightly-appcast-content-types.yml # .github/workflows/required-checks-drift.yml # .github/workflows/resolve-dispatch-ref.yml # .github/workflows/seed-derived-data.yml # .github/workflows/terminal-hang-diagnostics.yml # .github/workflows/test-e2e.yml # .github/workflows/test-ios.yml # .github/workflows/testbox-broker-guard.yml # .github/workflows/web-validation.yml
Why
The owned Macs upload at about 7.5 MB/s each (a per-host uplink cap: measured 6 to 7 MB/s to Cloudflare from 7s, 15 and mini-6 at once, single or 8 parallel streams). The 830 MB app-host product therefore takes 120 s p50 (199 s p90) of every owned compile admission, and about as long again for each owned consumer that downloads it (hq#661 workstream 5).
A third of those bytes are duplicates. Build/Products reaches every framework binary through
Versions/Currentsymlinks. Product extractors accept no symlinks, so packaging usedtar -h, which stored each framework binary three times: 1.9 GB on disk became 2.7 GB of tar.Change
Stage the tree as hard links with the symlinks followed (
pax -rwlL, the same treetar -hwrote) beside the DerivedData so the links stay on one volume, then tar the stage. tar stores each file once and every other path as a hard link. Applied to the three places that pack this product: compile admission, the seed workflow and E2E.tar -x(restore-app-host-test-product.sh, the rerun workflow),aa(layered products) andreuse_app_host_products.py unpack(which already accepts hard links) all extract the same files as before. Checked locally with a framework-shaped tree through all three..oand.swiftmodulefiles it links against.Measured
On a kept cmux10s product, same moment, mini under load:
tar -chf+ gzip -1 (before)tar -cf+ gzip -1Expected on an owned admission: about 35 s less upload and 13 s less packing, and about 35 s less download per owned consumer. I will post the before/after from real runs on hq#661.
🤖 Generated with Claude Code
Need help on this PR? Tag
@codesmith-botwith what you need. Autofix is disabled.Summary by cubic
Stores each app-host product file once in the product archive, cutting the archive from 830 MB to 572 MB and pack time from 41 s to 28 s. Build/Products reaches each framework binary through Versions/Current symlinks, so
tar -hstored every binary three times; on owned Macs that 830 MB upload costs about 120 s per compile admission.pax -rwlLbeside DerivedData, then tars the stage; compile admission, the seed workflow, and E2E all use it. The stage is also removed on any exit viatrap.tar -x,aa, andreuse_app_host_products.pyextract the same files as before, and the rerun workflow still gets the.oand.swiftmodulefiles it links against.Written for commit 7a2870f. Summary will update on new commits.
Summary by CodeRabbit