Pub/sub using Elixir's local Registry module.
Summary
Functions
Broadcasts message on given topic.
Return the child spec.
Subscribes the caller to the given topic.
Functions
@spec broadcast(EventStoreLite.t(), binary(), term()) :: :ok
Broadcasts message on given topic.
@spec child_spec(EventStoreLite.t()) :: [:supervisor.child_spec()]
Return the child spec.
@spec subscribe(EventStoreLite.t(), binary(), selector: (EventStoreLite.RecordedEvent.t() -> any()), mapper: (EventStoreLite.RecordedEvent.t() -> any()) ) :: :ok | {:error, term()}
Subscribes the caller to the given topic.