glm-5.3-flash
674120ad72
feat(websocket): WsTimeouts request extension for WS pump knobs (WS-17)
...
- WsTimeouts { idle, write } request extension mirrors ChannelsPolicy:
a deployment layers it on a WS route (bare-registry routes included)
to set the pump knobs per route
- precedence: extension present replaces the router state entirely;
absent falls back to SessionState (adapter-configured idle) and the
crate default write window — a Default impl never clobbers the
adapter-configured idle knob
- upgrade.rs module + handler docs now state the real defaults for
bare-registry routes (60 s idle + 60 s write, 64-session semaphore,
handler-private WsSessions) and the extension surface
- split_ws_to_bytes_idle_with_write exposes the WS-18 write window to
run_channels_session; acceptance test drives a bare-registry route
with a 150 ms extension idle window (1001 eviction observed)
Verification: scripts/verify.sh OK (343 passed), test-support suite
ok, clippy -D warnings clean, fmt clean
2026-08-30 21:48:03 +00:00
glm-5.3-flash
91483a74b4
docs: missing_docs sweep — 0 warnings + deny gate + publish-prep decisions (HY-02, HY-04, HY-11)
...
- document every public-API item across 18 files (openapi_spec model,
HttpAuthScheme/HttpServiceConfig, HttpClientBuildError + SharedHttpClient
accessors, RetryAfterMiddleware, GatewayDispatch, gateway error
mapping, CallRequest/SchemaQuery/SubscribeStream, HttpAdapter +
ALPNs + builders, decoy/healthz/state, WsSessions/WsPumps,
from_openapi/from_jsonschema/from_mcp/from_wss/to_mcp, lib.rs module
docs)
- enforcement: #![deny(missing_docs)] at crate root — stronger than CI
rustdocflags (every build incl. cfg(test), where rustdoc misses the
test-support module docs)
- HY-10 (opportunistic): all 8 docs.rs/alkhttp placeholder ADR links +
the one relative ../docs link converted to plain text; the 10
pre-existing private/redundant intra-doc-link warnings fixed —
RUSTDOCFLAGS="-D warnings" cargo doc is fully clean
- HY-11 decision: docs/ + tasks/ excluded from the published package
(contributor-facing design/process material; ADR references degrade
to plain text uniformly). cargo publish --dry-run: 38 files, ~889 KiB,
zero docs/ or tasks/ entries
- HY-04 decision: keep + document — frame_channel0_chunk's unwrap is
on serializing the acyclic EventEnvelope (unreachable failure);
# Panics on it and the adjacent WsClient senders state the contract
Verified: cargo test (299 + 5 TLS), --all-features (370 + suites),
--no-default-features (299), clippy --all-targets -D warnings
(default + all-features), fmt --check, cargo doc -D warnings clean,
cargo publish --dry-run --allow-dirty clean.
Tasks: review-001-missing-docs-sweep (final pending task; 42/42)
2026-08-30 08:25:18 +00:00
glm-5.3-flash
c93f7387ff
docs(websocket): detached task lifetime semantics (WS-10)
2026-08-29 13:46:57 +00:00
glm-5.3-flash
25975ac2a8
fix(websocket): configurable WS read idle timeout (WS-01)
2026-08-29 13:45:54 +00:00
glm-5.3-flash
fa73684ebe
fix(websocket): configurable WS session cap (WS-09)
2026-08-29 13:37:08 +00:00
glm-5.3-flash
4747a12c02
fix(websocket): retain WsPumps handle on the server path (WS-08)
2026-08-29 13:31:33 +00:00
glm-5.3-flash
92cc11a74f
fix(websocket): byte-based caps for pending buffer + inbound WS sizes (WS-05, WS-06)
2026-08-29 12:00:04 +00:00
glm-5.3-flash
314472012d
fix(server): hyper knobs, decoy fidelity, cache + builder fixes (SRV-04..SRV-10)
...
- SRV-04: TokioTimer on h1+h2 builder, header_read_timeout 10s,
h1 keep-alive on, h2 keep-alive 30s/10s; concurrency boundary documented
- SRV-05: with_decoy rebuild keeps extra routes (clone, not take)
- SRV-07: method_not_allowed_fallback serves the nginx-shaped 405
- SRV-08: UTF-8 percent-decoding, literal '+', tokio::fs syscalls
- SRV-09: /openapi.json cached at construction, generic 500 body,
to_openapi returns Result (expect removed)
- SRV-10: ChannelsPolicy extension injection point on the WS upgrade;
single token resolution via route ordering (WS layer before the
router-wide auth route_layer)
Verification: cargo test 265 passed; --all-features server::/to_openapi::
green; clippy + fmt clean on touched files (remaining tree noise is a
parallel agent's in-flight from_mcp/from_wss/forward work)
2026-08-29 10:47:44 +00:00
glm-5.3-flash
a9ac6f6cbd
fix(websocket): lossless EOF signal + pending sweep (WS-02, CON-02)
...
- Replace the axum/tungstenite pump paths' Notify-based read-EOF signal
with a retained tokio watch channel: a late subscriber (monitor
spawned after session setup, or pump EOF before the receiver is
taken) still observes EOF (WS-02).
- from_wss drop monitor: on EOF (or session close) fail all pendings
retryable, then keep sweeping the pending map every 1 s — calls
registered after the initial fail_all (the forgotten-session import
path) resolve instead of hanging (CON-02).
- Tests: drop-during-registration race variants (forget + held
session) and a post-EOF registration resolved via the sweep; the
existing no-hang test stays green.
cargo test (219), cargo test --features wss (231, 3x for flake check),
cargo clippy --all-targets -- -D warnings, cargo fmt --check
2026-08-29 09:36:34 +00:00
glm-5.3-flash
3a906cbd6a
feat(adapters): from_wss consumer adapter behind the wss feature (ADR-070)
...
- FromWss: dial wss:// -> split_tungstenite_to_bytes (client-side twin
of the axum WS byte-adapter; one seam, both directions, OQ-01) ->
Connection::from_bidi(b"alk/channels") -> alkcall ChannelClient
(channel 0 install + dispatch loop) -> alkcall from_call importer.
No protocol fork: specs mirror the remote, provenance FromCall.
- Drop semantics (OQ-03 v1): session drop -> monitor fails all
in-flight pendings retryable CONNECTION_CLOSED (WsPumps::read_eof
Notify); no 30s-deadline hang.
- Bearer token via constructor/assembly layer (ADR-014 no-env-vars).
Production fix in the WS server half (upgrade.rs): the upgrade
identity now propagates to channel 0's CallConnection (was
AuthContext::anonymous -> dispatcher saw no identity, ACL checks ran
unauthenticated; services/list filtered scoped ops for all callers).
9 in-module tests incl. full round-trip consumer<->server (both halves
of the adapter together), ACL end-to-end, drop-no-hang.
Verified: cargo test (227 lib default), --all-features (227 lib + 5
MCP + 10 WS integration), clippy -D warnings (both), fmt.
2026-08-28 14:54:09 +00:00
glm-5.3-flash
4ba9b652b3
feat(websocket): WS upgrade route + channels session (server producer half)
...
- src/websocket/byte_adapter.rs: production WsByteStream from the POC —
inbound bounded mpsc (64 slots, backpressure), outbound chunk parser
emitting one WS message per chunk with 1 MiB split; write-side
backpressure now uses futures mpsc poll_ready (POC spin-wait fixed);
text messages closed with 1002; close mapping per websocket.md
- src/websocket/upgrade.rs: /alk/channels upgrade route — bearer auth
(401 unresolvable), identity attached to the channels Connection,
ChannelsAdapter + install_channel_zero running
Dispatcher::run_loop_single_stream
- test_support module (feature test-support): WsClient, chunk/frame
assemblers; shared with from_wss consumer path (ADR-070)
- tests/ws_upgrade_session.rs: 10 integration tests — call round-trip,
services/list ACL-filtered, 3 MiB split, interleaved calls, ACL 403,
internal-op NOT_FOUND, text->1002 close, disconnect mid-call no-hang
Verified: cargo test (95), cargo test --all-features (95+10),
clippy -D warnings (default + all-features), fmt.
2026-08-28 08:47:13 +00:00