Skip to content

docs(design): plan daemon thread-per-conn bench at 100/1K/10K concurrent (#1933) - #3891

Merged
oferchen merged 1 commit into
masterfrom
design/daemon-thread-per-conn-bench
May 7, 2026
Merged

oferchen merged 1 commit into
masterfrom
design/daemon-thread-per-conn-bench

Conversation

@oferchen

@oferchen oferchen commented May 7, 2026

Copy link
Copy Markdown
Owner

Summary

  • Slim runnable bench plan for the synchronous thread-per-connection daemon at 100 / 1 000 / 10 000 concurrent rsync:// pulls on Linux loopback.
  • Cross-references the static analysis in docs/audits/daemon-thread-per-connection-scalability.md (Split branding tests into module #1673) and the broader plan in docs/design/daemon-tpc-benchmark-plan.md; complements rather than replaces them.
  • Defines harness, ulimits (-u 65536, -n 65536), workload (1 MiB pull per connection), metrics (ttfb, completion p99, peak RSS, peak thread count), pass criteria (W1k succeeds within 30 s; W10k exploratory), and the downstream feed into Accept quoted fallback override values #1934 and Normalize quoted fallback keywords #1935.

Test plan

  • docs/design/daemon-thread-per-conn-bench.md is under 130 lines (currently 124).
  • Markdown renders cleanly on GitHub (no broken cross-references to audit / RFC / sibling plan).
  • No code changes; documentation-only PR, so CI passes the fmt + clippy + nextest matrix unchanged.

Slim runnable plan complementing the broader benchmark plan. Specifies
the minimum harness needed to land first measured numbers on Linux
loopback at 100/1K/10K concurrent rsync:// pulls so #1934 RFC and #1935
async-listener work can compare sync vs async paths against quantified
sync-baseline ttfb, completion p99, peak RSS, and thread count.
@github-actions github-actions Bot added the documentation Improvements or additions to documentation label May 7, 2026
@oferchen
oferchen merged commit 27e66e0 into master May 7, 2026
8 checks passed
@oferchen
oferchen deleted the design/daemon-thread-per-conn-bench branch May 8, 2026 03:52
oferchen added a commit that referenced this pull request May 18, 2026
…#3891)

Slim runnable plan complementing the broader benchmark plan. Specifies
the minimum harness needed to land first measured numbers on Linux
loopback at 100/1K/10K concurrent rsync:// pulls so #1934 RFC and #1935
async-listener work can compare sync vs async paths against quantified
sync-baseline ttfb, completion p99, peak RSS, and thread count.
oferchen added a commit that referenced this pull request Aug 24, 2026
…#3891)

Slim runnable plan complementing the broader benchmark plan. Specifies
the minimum harness needed to land first measured numbers on Linux
loopback at 100/1K/10K concurrent rsync:// pulls so #1934 RFC and #1935
async-listener work can compare sync vs async paths against quantified
sync-baseline ttfb, completion p99, peak RSS, and thread count.
oferchen added a commit that referenced this pull request Aug 24, 2026
EDG-PANIC.1: workspace audit of bare slice indexing patterns on
attacker-controlled buffers (protocol/transfer/checksums/compress).
~314 indexing sites reviewed; only the two known UTS-18 sites in
BufferedMap surfaced as suspect, both with a fix in flight via
PR #5566. All other indexing is bounds-checked on the prior line,
backed by fixed-size [u8; N] arrays, min-clamped, or covered by a
length-prefix or library contract. Findings written to
docs/audits/edg-panic-1-bare-slice-indexing.md with follow-up items
enumerated as future EDG-PANIC tasks.

EDG-PANIC.3: pin the BufferedMap basis-slice bounds contract with
five negative-bounds unit tests against map_ptr (the BufferedMap
"slice" accessor):

  - offset past EOF returns Err
  - length overflow (usize::MAX) returns Err
  - u64::MAX offset returns Err
  - offset == file_size with non-zero len returns Err
    (offset == file_size with zero len is a legitimate empty slice)
  - range straddling EOF returns Err

Each test asserts io::ErrorKind::UnexpectedEof so a future change
that drops or weakens the saturating_add guard is caught at the
test boundary. Mirrors the malformed delta stream attack surface
UTS-18 root-caused (range end index N out of range for slice of
length M aborting the process).

Refs: #3891, #3893
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

documentation Improvements or additions to documentation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant