Coordinated Shutdown
Get Started
type ShutdownHook interface {
// Execute runs the shutdown logic for this hook.
//
// Parameters:
// - ctx: The context for cancellation and deadlines.
// - actorSystem: The ActorSystem being shut down.
//
// Returns:
// - error: An error if the shutdown logic fails, or nil on success.
Execute(ctx context.Context, actorSystem ActorSystem) error
// Recovery returns the ShutdownHookRecovery configuration for this hook.
//
// This determines how failures are handled, including retry and recovery strategies.
//
// Returns:
// - *ShutdownHookRecovery: The recovery configuration for this hook.
Recovery() *ShutdownHookRecovery
}Recovery Strategies
Last updated