LocalFirstStateEventBus
class LocalFirstStateEventBus(val distributedBus: DistributedStateEventBus, val localBus: LocalStateEventBus = InMemoryStateEventBus()) : StateEventBus, LocalFirstMessageBus<StateEvent<*>, StateEventExchange<*>>
State event bus that prioritizes local message delivery before distributed delivery. Messages are first sent to local subscribers within the same JVM instance, then forwarded to the distributed bus for cross-instance communication. This ensures low-latency local processing while maintaining consistency across instances.
Parameters
distributedBus
The distributed state event bus for cross-instance messaging.
localBus
The local state event bus for same-instance messaging (default: InMemoryStateEventBus).
Constructors
Link copied to clipboard
constructor(distributedBus: DistributedStateEventBus, localBus: LocalStateEventBus = InMemoryStateEventBus())
Functions
Link copied to clipboard
Receives messages for the specified subscription.
Link copied to clipboard
Creates a single message source with an explicit transport readiness boundary.
Link copied to clipboard
Creates the message source owned by a me.ahoo.wow.runtime.WowRuntime dispatcher.
Link copied to clipboard
Sends a message through the message bus.