InMemoryEventBus class

In-process EventSink + EventSource backed by a broadcast stream.

Pairs with InMemoryBroker for single-isolate setups: a GisilaRose dashboard embedded in the same process can subscribe directly without Redis. Retains a bounded ring buffer of recent events so a dashboard that attaches late still sees backfill via history.

Implemented types

Constructors

InMemoryEventBus({int historySize = 1000})

Properties

hashCode int
The hash code for this object.
no setterinherited
historySize int
How many recent events to retain for history backfill.
final
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

close() Future<void>
Releases any resources / connections held by the sink.
override
emit(QueueEvent event) Future<void>
Publishes event. Implementations must never throw into the caller — observability must not break task processing; swallow/log transport errors internally instead.
override
events() Stream<QueueEvent>
A broadcast stream of every event observed from now on.
override
history({int limit = 500}) Future<List<QueueEvent>>
Recent events buffered before events was subscribed, oldest first. Used to backfill a freshly-started dashboard. Empty when unsupported.
override
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited