pub struct HttpNonquiescentShutdown { /* private fields */ }Expand description
Caller-owned settlement authority for a bounded, nonquiescent HTTP stop.
This handle retains every connection child that did not cooperate with the
listener’s shutdown cancellation before its bounded drain elapsed. Call
Self::poll_settlement or Self::settle_for for bounded observation,
or Self::settle when the caller deliberately elects to await eventual
quiescence. Dropping the handle does not create FastMCP global retention;
the caller’s asupersync region remains the task owner.
Implementations§
Source§impl HttpNonquiescentShutdown
impl HttpNonquiescentShutdown
Sourcepub fn listener_error(&self) -> Option<&McpError>
pub fn listener_error(&self) -> Option<&McpError>
Returns the listener failure that accompanied this shutdown, if any.
Sourcepub fn poll_settlement(&mut self) -> HttpShutdownSettlement
pub fn poll_settlement(&mut self) -> HttpShutdownSettlement
Reaps completed children without waiting.
Sourcepub async fn settle_for(&mut self, timeout: Duration) -> HttpShutdownSettlement
pub async fn settle_for(&mut self, timeout: Duration) -> HttpShutdownSettlement
Waits no longer than timeout for cooperative completion.
Sourcepub async fn settle(self, cx: &Cx) -> McpResult<()>
pub async fn settle(self, cx: &Cx) -> McpResult<()>
Waits until each retained child has reached a terminal state.
This is intentionally an explicit caller choice: synchronous code can ignore cancellation indefinitely, so FastMCP never performs this unbounded join inside the public listener shutdown path.