CommBus.Storage.Ecto (CommBus v0.1.0)

Copy Markdown View Source

Default Ecto-backed storage adapter for CommBus.

Configuration

config :comm_bus, CommBus.Storage.Ecto,
  repo: MyApp.Repo,
  entry_schema: CommBus.Storage.Ecto.EntrySchema,
  conversation_schema: CommBus.Storage.Ecto.ConversationSchema

Only :repo is required; the schema modules default to the ones bundled with CommBus. Projects may override them to extend fields or change table names.

Summary

Functions

Delegates entry deletion to the EctoAdapter with this module's configuration.

Delegates entry lookup to the EctoAdapter with this module's configuration.

Delegates entry listing to the EctoAdapter with this module's configuration.

Delegates conversation loading to the EctoAdapter with this module's configuration.

Delegates conversation storage to the EctoAdapter with this module's configuration.

Delegates entry storage to the EctoAdapter with this module's configuration.

Delegates conversation update to the EctoAdapter with this module's configuration.

Functions

delete_entry(id)

Delegates entry deletion to the EctoAdapter with this module's configuration.

get_entry(id)

Delegates entry lookup to the EctoAdapter with this module's configuration.

list_entries(opts)

Delegates entry listing to the EctoAdapter with this module's configuration.

load_conversation(id)

Delegates conversation loading to the EctoAdapter with this module's configuration.

store_conversation(conversation)

Delegates conversation storage to the EctoAdapter with this module's configuration.

store_entry(entry)

Delegates entry storage to the EctoAdapter with this module's configuration.

update_conversation(id, updates)

Delegates conversation update to the EctoAdapter with this module's configuration.