Repository navigation
refactor(gateway): split the request pipeline into stages and server.rs into modules - #166
Merged
Merged
Conversation
…rs into modules The 1100-line pipeline fn becomes one function per pipeline step (probe, read, admit, route, start) plus two submodules: hop (try the candidates in order) and relay (hand the response to the client, with the per-chunk work on a Relay struct). server.rs keeps the router, passthrough and the event helpers; AppState/Runtime move to state.rs (credentials and upstream-status bookkeeping in child modules), the per-upstream HTTP clients to outbound.rs, the model listing and the WebSocket upgrade to their own files, and seed_latency to latency.rs. No behaviour change. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
fylorn
force-pushed
the
refactor/split-pipeline
branch
from
September 24, 2026 07:08
2989a75 to
ed65391
Compare
Merged
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.
Pure refactor of `crates/tw-gateway/src/server.rs` (2887 lines). No behaviour change; all tests pass unchanged.
Pipeline (`server/pipeline.rs`, was one ~1100-line fn):
Other moves
🤖 Generated with Claude Code