[CTX-0055] fix(transport): enforce sustained refill and bounded burst - #115
Merged
Merged
Conversation
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.
Scope
Task: CTX-0055. Closes #102.
Enforce sustained refill with capped initial burst and rolling burst ceiling in the TS/Rust client helper. Count and admission share a nondecreasing clock. Validate TS numeric inputs before mutation; preserve native Rust u64 time support. No wire/protocol version or server-enforcement change; reconnect #106 remains separate.
Review and verification
Independent APPROVE: PX-0252. Delivery commander read the full diff and verified all three approved blobs unchanged. Local scoped Bun: 26 passed; full Bun: 301 passed; full Rust: 65 passed. Typecheck, build, pinned Prettier, markdownlint, scoped oxlint, cargo fmt/check/clippy (offline, locked, warnings denied), diff check and prepush gitleaks passed. Existing local synthetic fixtures only, no live campaign. Pinned Prettier is authoritative; previously documented oxfmt defaults differ.
Documentation and ordering
Canonical docs synchronization is prepared and tracked separately in bitty-terminal-docs CarryCtx CTX-0026, scope specifications/devtools-rfc.md, requirements PX-0245/PX-0253. Docs are pending, not delivered or verified. User explicitly authorizes code merge and closing linkage while this docs task exists; CarryCtx implementation task stays REVIEW, not completed. Delivery sequence: CTX-0055, CTX-0059, CTX-0053. No snapshots/export/publication or worktree cleanup.
Complexity: amortized O(1) admission, worst O(burst) eviction, O(burst) space.