Jido.Signal.Journal.Adapters.ETS (Jido v1.1.0-rc.2)

View Source

ETS-based implementation of the Journal persistence behavior. Uses separate ETS tables for signals, causes, effects, and conversations.

Configuration

The adapter requires a prefix for table names to allow multiple instances:

{:ok, _pid} = Jido.Signal.Journal.Adapters.ETS.start_link("my_journal_")
{:ok, journal} = Jido.Signal.Journal.new(Jido.Signal.Journal.Adapters.ETS)

This will create tables with names:

  • :my_journal_signals
  • :my_journal_causes
  • :my_journal_effects
  • :my_journal_conversations

Summary

Functions

Returns a specification to start this module under a supervisor.

Cleans up all ETS tables used by this adapter instance.

Gets all signals in the journal.

Starts the ETS adapter with the given table name prefix.

Types

t()

@type t() :: %Jido.Signal.Journal.Adapters.ETS{
  causes_table: atom(),
  conversations_table: atom(),
  effects_table: atom(),
  signals_table: atom()
}

Functions

child_spec(init_arg)

Returns a specification to start this module under a supervisor.

See Supervisor.

cleanup(pid)

Cleans up all ETS tables used by this adapter instance.

get_all_signals(pid)

Gets all signals in the journal.

start_link(prefix)

Starts the ETS adapter with the given table name prefix.