perf(agent): isolate bulk traffic on a dedicated console - #1360
Open
appcypher wants to merge 2 commits into
Open
perf(agent): isolate bulk traffic on a dedicated console#1360appcypher wants to merge 2 commits into
appcypher wants to merge 2 commits into
Conversation
appcypher
force-pushed
the
appcypher/agent-bulk-console
branch
from
August 16, 2026 05:00
2851175 to
615a46a
Compare
5 tasks
appcypher
force-pushed
the
appcypher/agent-bulk-console
branch
from
August 16, 2026 09:28
615a46a to
f8d3530
Compare
Add a bounded second virtio-console path for generation-7 raw records while keeping control messages on the existing agent port. Bind both ports to one boot, lease correlation ranges to random client incarnations, and quarantine disconnected ranges until agentd confirms owner-scoped cleanup. Use bounded fair schedulers, cross-lane merge state, cancellation tombstones, and transport-health propagation so bulk stalls cannot block control traffic or corrupt a recycled operation.
appcypher
force-pushed
the
appcypher/agent-bulk-console
branch
from
August 16, 2026 09:34
f8d3530 to
37fb8d1
Compare
Raise filesystem bulk records to 3 MiB and fuse bounded guest turns so one-vCPU transfers do less scheduling and copying work. Make guest output routing byte-bounded without disconnecting healthy clients on short bursts, prioritize the control lane, preserve cleanup cuts, and bypass cross-lane actors in combined mode. Break the in-process SSH duplex backpressure cycle and restore buffered host-copy publication as the historical default while retaining explicit file durability.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
TL;DR
Put generation-7 raw records on a dedicated internal virtio-console lane, fix the measured bottlenecks, and preserve one public
agent.sock.Description
agent-bulkconsole.copy_to_hostpublication as the default; callers can still explicitly request a file sync:sandbox .fs() .copy_to_host_with_options( "/guest/data", "/host/data", HostCopyOptions { durability: HostCopyDurability::File, }, ) .await?;The same fresh exact-head comparison is shown on every PR in this stack. “After” means all four PRs together at
7f3f44ce, with automatic dual-port selection andlocal-shm-v1enabled; the original baseline is05f53e7a. Both profiles ran twice in ABBA order.Environment: OVH Advance-4, Linux/KVM, 1-vCPU guest, host CPU 8 affinity, guest tmpfs, public Rust SDK, verified payload hashes, and empty stderr. After artifacts were rebuilt from
7f3f44ceagainst libkrunff087a1.Test Plan
cargo fmt --all -- --checkcargo check -p microsandbox-protocol -p microsandbox-agent-client -p microsandbox-runtime -p microsandboxcargo clippy -p microsandbox-protocol -p microsandbox-agent-client -p microsandbox-runtime -p microsandbox --lib -- -D warningscargo test -p microsandbox-protocol -p microsandbox-agent-client -p microsandbox-runtime -p microsandbox --lib— 823 passed, 3 ignored