cancel_stream
Stop an in-flight multiplexed stream server-side — abandoning the call does not.
cancel_stream(target_stream_id: int, reason: str = 'ClientUnneeded') -> CancelStreamAckParameters
ParameterTypeRequired
target_stream_idintegerrequiredThe stream to cancel.
reasonCancellationReasonoptionalDefaults to ClientUnneeded.
Returns
FieldTypePresence
target_stream_idintegeralwaysEchoed back.
cancelled_at_unix_nanos64-bit integeralwaysWhen the server stopped.
Wire tier only
There is no HTTP equivalent: an HTTP response has no stream id to name, and closing the response body is the whole cancellation story there.
See also
Was this page helpful?