archivist_lib::component_lifecycle

Function on_stop_request

Source
pub async fn on_stop_request<F, Fut>(
    request_stream: LifecycleRequestStream,
    cb: F,
)
where F: FnOnce() -> Fut, Fut: Future<Output = ()>,
Expand description

Serves the Lifecycle protocol from the component runtime used for controlled shutdown of the archivist. When Stop is requrested executes the given callback.