Immudb (immudb_elixir v0.2.0)

Link to this section Summary

Link to this section Functions

Link to this function

change_password(socket, list)

@spec change_password(Immudb.Socket.t(),
  user: String.t(),
  old_password: String.t(),
  new_password: String.t()
) :: {:error, String.t() | atom()} | {:ok, String.t()}
Link to this function

change_permission(socket, list)

@spec change_permission(Immudb.Socket.t(),
  action: :GRANT | :REVOKE,
  username: String.t(),
  database: String.t(),
  permission: atom()
) :: {:error, String.t()} | {:ok, nil}
Link to this function

compact_index(socket)

@spec compact_index(Immudb.Socket.t()) :: {:error, String.t()} | {:ok, nil}
Link to this function

count(socket, prefix)

@spec count(Immudb.Socket.t(), [binary()]) ::
  {:error, String.t() | atom()} | {:ok, Immudb.Schemas.EntryCount.t()}
Link to this function

count_all(socket)

@spec count_all(Immudb.Socket.t()) ::
  {:error, String.t() | atom()} | {:ok, Immudb.Schemas.EntryCount.t()}
Link to this function

create_database(socket, database_name)

@spec create_database(Immudb.Socket.t(), binary()) ::
  {:error, String.t() | atom()} | {:ok, nil}
Link to this function

create_user(socket, list)

@spec create_user(Immudb.Socket.t(),
  user: String.t(),
  password: String.t(),
  database: String.t(),
  permission: atom()
) :: {:error, String.t() | atom()} | {:ok, nil}
Link to this function

current_state(socket)

@spec current_state(Immudb.Socket.t()) :: {:error, String.t() | atom()} | {:ok, nil}
Link to this function

describe_table(socket, table_name)

@spec describe_table(Immudb.Socket.t(), String.t()) ::
  {:error, String.t()} | {:ok, nil}
Link to this function

get(socket, key)

@spec get(Immudb.Socket.t(), binary()) ::
  {:error, String.t() | atom()} | {:ok, Immudb.Schemas.Entry.t()}
Link to this function

get_all(socket, keys)

@spec get_all(Immudb.Socket.t(), [binary()]) ::
  {:error, String.t() | atom()} | {:ok, Immudb.Schemas.Entries.t()}
@spec health(Immudb.Socket.t()) :: {:error, String.t() | atom()} | {:ok, nil}
Link to this function

history(socket, key, list)

@spec history(Immudb.Socket.t(), binary(),
  offset: integer(),
  limit: integer(),
  desc: boolean(),
  since_tx: integer()
) :: {:error, String.t() | atom()} | {:ok, Immudb.Schemas.Entries.t()}
Link to this function

list_databases(socket)

@spec list_databases(Immudb.Socket.t()) :: {:error, String.t() | atom()} | {:ok, nil}
Link to this function

list_tables(socket)

@spec list_tables(Immudb.Socket.t()) :: {:error, String.t()} | {:ok, nil}
Link to this function

list_users(socket)

@spec list_users(Immudb.Socket.t()) ::
  {:error, String.t() | atom()} | {:ok, [User.t()]}
Link to this function

login(socket, user, password)

@spec login(Immudb.Socket.t(), String.t(), String.t()) ::
  {:error, String.t() | atom()} | {:ok, String.t()}
@spec logout(Immudb.Socket.t()) :: {:error, String.t() | atom()} | {:ok, nil}
@spec new([{:url, String.t()}]) :: {:ok, Immudb.Socket.t()} | {:error, String.t()}
@spec new(
  host: String.t(),
  port: integer(),
  username: String.t(),
  password: String.t(),
  database: String.t()
) :: {:ok, Immudb.Socket.t()} | {:error, String.t()}
Link to this function

scan(socket, list)

@spec scan(Immudb.Socket.t(),
  seek_key: binary(),
  prefix: binary(),
  desc: binary(),
  limit: integer(),
  since_tx: binary(),
  no_wait: boolean()
) :: {:error, String.t() | atom()} | {:ok, Immudb.Schemas.Entries.t()}
Link to this function

set(socket, key, value)

@spec set(Immudb.Socket.t(), binary(), binary()) ::
  {:error, String.t() | atom()} | {:ok, Immudb.Schemas.TxMetaData.t()}
Link to this function

set_active_user(socket, list)

@spec set_active_user(Immudb.Socket.t(), active: boolean(), username: String.t()) ::
  {:error, String.t()} | {:ok, nil}
Link to this function

set_all(socket, kvs)

@spec set_all(Immudb.Socket.t(), [{binary(), binary()}]) ::
  {:error, String.t() | atom()} | {:ok, Immudb.Schemas.TxMetaData.t()}
Link to this function

set_reference(socket, list)

@spec set_reference(Immudb.Socket.t(),
  key: binary(),
  referenced_key: binary(),
  at_tx: integer(),
  bound_ref: boolean(),
  no_wait: boolean()
) :: {:error, String.t() | atom()} | {:ok, Immudb.Schemas.TxMetaData.t()}
@spec set_reference(Immudb.Socket.t(),
  key: binary(),
  referenced_key: binary(),
  at_tx: integer(),
  bound_ref: boolean(),
  no_wait: boolean(),
  prove_since_tx: integer()
) :: {:error, String.t() | atom()} | {:ok, Immudb.Schemas.VerifiableTx.t()}
Link to this function

sql_exec(socket, sql)

@spec sql_exec(Immudb.Socket.t(), String.t()) :: {:error, String.t()} | {:ok, nil}
Link to this function

sql_exec(socket, sql, kvs)

@spec sql_exec(Immudb.Socket.t(), String.t(), [{String.t(), String.t()}]) ::
  {:error, String.t()} | {:ok, nil}
Link to this function

sql_query(socket, sql, kvs)

@spec sql_query(Immudb.Socket.t(), String.t(), [{String.t(), String.t()}]) ::
  {:error, String.t()} | {:ok, nil}
Link to this function

stream_get(socket, list)

@spec stream_get(Immudb.Socket.t(),
  key: String.t(),
  at_tx: integer(),
  since_tx: integer()
) ::
  {:error, String.t() | atom()} | {:ok, nil}
Link to this function

stream_history(socket, key, list)

@spec stream_history(Immudb.Socket.t(), binary(),
  offset: integer(),
  limit: integer(),
  desc: boolean(),
  since_tx: integer()
) :: {:error, String.t() | atom()} | {:ok, Immudb.Schemas.Entries.t()}
Link to this function

stream_scan(socket, list)

@spec stream_scan(Immudb.Socket.t(),
  seek_key: binary(),
  prefix: binary(),
  desc: binary(),
  limit: integer(),
  since_tx: binary(),
  no_wait: boolean()
) :: {:error, String.t() | atom()} | {:ok, Immudb.Schemas.Entries.t()}
Link to this function

stream_verifiable_get(socket, list)

@spec stream_verifiable_get(Immudb.Socket.t(),
  key: String.t(),
  at_tx: integer(),
  since_tx: integer(),
  prove_since_tx: integer()
) :: {:error, String.t() | atom()} | {:ok, nil}
Link to this function

tx_by_id(socket, tx)

@spec tx_by_id(Immudb.Socket.t(), binary()) ::
  {:error, String.t() | atom()} | {:ok, nil}
Link to this function

tx_scan(socket, list)

@spec tx_scan(Immudb.Socket.t(),
  initial_tx: integer(),
  limit: integer(),
  desc: boolean()
) ::
  {:error, String.t() | atom()} | {:ok, Immudb.Schemas.TxList.t()}
Link to this function

use_database(socket, database_name)

@spec use_database(Immudb.Socket.t(), [{:database_name, String.t()}]) ::
  {:error, String.t()} | {:ok, String.t()}
Link to this function

use_snapshot(socket, since_tx, as_before_tx)

@spec use_snapshot(Immudb.Socket.t(), integer(), integer()) ::
  {:error, String.t() | atom()} | {:ok, nil}
Link to this function

verifiable_get(socket, key)

@spec verifiable_get(Immudb.Socket.t(), binary()) ::
  {:error, String.t() | atom()} | {:ok, Immudb.Schemas.VerifiableEntry.t()}
Link to this function

verifiable_set(socket, key, value)

@spec verifiable_set(Immudb.Socket.t(), binary(), binary()) ::
  {:error, String.t() | atom()} | {:ok, Immudb.Schemas.VerifiableTx.t()}
Link to this function

verifiable_set_reference(socket, list)

Link to this function

verifiable_sql_get(socket, params)

@spec verifiable_sql_get(Immudb.Socket.t(), map()) ::
  {:error, String.t()} | {:ok, nil}
Link to this function

verifiable_tx_by_id(socket, tx, prove_since_tx)

@spec verifiable_tx_by_id(Immudb.Socket.t(), binary(), binary()) ::
  {:error, String.t() | atom()} | {:ok, nil}