GracefullyStoppable
Interface for components that support graceful shutdown.
Implementations of this interface provide both synchronous and asynchronous graceful stop operations. The synchronous stop method has a default timeout of 30 seconds; if shutdown does not complete within that window, the call returns without guaranteeing all in-flight operations have finished. Use stop with a custom Duration to adjust the timeout, or call stopGracefully directly for fully asynchronous shutdown.
This is particularly useful for message dispatchers, connection pools, and other resources that need to complete in-flight operations before terminating.
See also
for the standard close contract