Etso v0.1.3 Etso.Adapter.TableRegistry View Source

Provides convenience function to spin up a Registry, which is used to hold the Table Servers (registered by GenServer when starting up), alongside their ETS tables (registered when the Table Server starts).

Link to this section Summary

Functions

Returns Child Specification for the Table Registry that will be associated with the repo.

Returns the ETS table associated with the given repo which is used to hold data for schema.

Registers the ETS table associated with the given repo which is used to hold data for schema.

Link to this section Functions

Returns Child Specification for the Table Registry that will be associated with the repo.

Link to this function

get_table(repo, schema)

View Source
get_table(Etso.repo(), Etso.schema()) :: {:ok, Etso.table()} | {:error, term()}

Returns the ETS table associated with the given repo which is used to hold data for schema.

Link to this function

register_table(repo, schema, table_reference)

View Source
register_table(Etso.repo(), Etso.schema(), Etso.table()) ::
  :ok | {:error, term()}

Registers the ETS table associated with the given repo which is used to hold data for schema.