ExESDB.Commanded.AggregateListenerSupervisor (ex_esdb_commanded v0.9.0)

DynamicSupervisor for managing AggregateListener processes.

Uses Swarm for distributed process registration. Each supervisor is uniquely identified by a combination of store_id and node().

Summary

Functions

Returns a specification to start this module under a supervisor.

Lists all active listeners for a store.

Starts a new AggregateListener under supervision.

Returns statistics for all listeners managed by this supervisor.

Stops a specific AggregateListener.

Stops all listeners for a given stream.

Functions

child_spec(arg)

Returns a specification to start this module under a supervisor.

See Supervisor.

hash_key(store_id)

list_listeners(store_id)

@spec list_listeners(atom()) :: [map()]

Lists all active listeners for a store.

start_link(opts)

start_listener(config)

@spec start_listener(map()) :: {:ok, pid()} | {:error, term()}

Starts a new AggregateListener under supervision.

Returns the PID of the started listener or an error.

stats(store_id)

@spec stats(atom()) :: map()

Returns statistics for all listeners managed by this supervisor.

stop_listener(store_id, stream_id)

@spec stop_listener(atom(), String.t()) :: :ok

Stops a specific AggregateListener.

stop_listeners_for_stream(store_id, stream_id)

@spec stop_listeners_for_stream(atom(), String.t()) :: :ok

Stops all listeners for a given stream.

swarm_key(store_id)