From eceae2781ab8d3972b4113f4f02f162e5513eb5c Mon Sep 17 00:00:00 2001 From: Lilleman auf Larv Date: Mon, 28 Sep 2026 10:28:15 +0200 Subject: [PATCH] Name the unbind's path in the drain decision, and drop a request() doc a bind falsifies --- docs/decisions.md | 8 ++++---- src/outgoing-requests.ts | 2 +- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/docs/decisions.md b/docs/decisions.md index 7871d01..8772219 100644 --- a/docs/decisions.md +++ b/docs/decisions.md @@ -584,7 +584,7 @@ rule and an index of the titles below. a peer's own `unbind` take `end()`: nothing on a dead link can answer, an abort means stop now, and a peer that has declared itself finished will not answer what it still owes, so draining any of the three would only hold a socket open for the timeout. `unbind()` sends its own PDU through - `request()` past both the window and the drain gate, because it must go out either way. + `requestPastDrainGateAndWindow()`, because it must go out either way. `shutdownTimeout` stays a session option rather than a `close()` argument: `server()` builds sessions on the caller's behalf, so the option is the only composition point. `SmppServer.close()` reports each session's unfinished drain through `serverError`, because its own result says nothing @@ -772,9 +772,9 @@ rule and an index of the titles below. `OutgoingRequests.canCarry()` reads it rather than `closed`. The gate is told what happened and never reads back into the session: a collaborator that has to ask does not own its decision, which is how the first cut ended up answering the same question two different ways at admit and at - release. The retry in `requestPastDrain()` asks `gate.awaitsNextLink()` rather than `canCarry()`, which also - reads the socket: a loop condition the gate does not gate on spins against a gate that admits it - straight back. + release. The retry in `requestPastDrain()` asks `gate.awaitsNextLink()` rather than `canCarry()`, + which also reads the socket: a loop condition the gate does not gate on spins against a gate that + admits it straight back. ## Internals and tests diff --git a/src/outgoing-requests.ts b/src/outgoing-requests.ts index b4d064b..f2c92f9 100644 --- a/src/outgoing-requests.ts +++ b/src/outgoing-requests.ts @@ -81,7 +81,7 @@ export class OutgoingRequests { this.pending.settle(seqNr, { err }); } - /** Sends a request once the gate has a link and the window a slot, and resolves with the peer's response. */ + /** Sends a request and resolves with the peer's response. */ request(input: PduObjectInput, options: SendOptions): Promise> { // Ahead of the drain, so a misuse is named as one rather than blamed on the shutdown. const wrong = misuse(input);