WowRuntime

High-level owner and lifecycle orchestrator for the complete Wow runtime.

Startup uses a readiness barrier: every component is prepared before any component starts processing. Shutdown first reaches global quiescence, then stops components in reverse order under one shared deadline. A fatal runtime component error initiates the same complete-runtime shutdown path.

Constructors

Link copied to clipboard
constructor(components: List<RuntimeComponent>, shutdownTimeout: Duration, shutdownQuietPeriod: Duration)

Properties

Link copied to clipboard

Unmodifiable snapshot of the registered component topology.

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard

Hot, replayable completion of the runtime, including fatal errors.

Functions

Link copied to clipboard
fun claimTerminationControl(onTermination: (Throwable?) -> Unit): Disposable

Exclusively claims the trusted termination control plane.

Link copied to clipboard
open override fun close()

Closes this resource by performing a graceful shutdown with a 30-second timeout.

Link copied to clipboard
fun forceStop()
Link copied to clipboard
fun start(): Mono<Void>

Starts the runtime and completes only after the readiness barrier opens.

Link copied to clipboard
open override fun stop()

Uses this runtime's global deadline instead of the generic 30-second wait. The raw terminal result keeps this trusted boundary independent of public observer delivery capacity.

open override fun stop(timeout: Duration)

Applies timeout only to the caller's wait. Runtime shutdown remains governed by its single configured global deadline.

Link copied to clipboard
open override fun stopGracefully(): Mono<Void>

Asynchronously closes this resource with graceful shutdown.