17 lines
287 B
Elixir
17 lines
287 B
Elixir
|
defmodule Backend.Elasticsearch.Store do
|
||
|
@behaviour Elasticsearch.Store
|
||
|
|
||
|
alias Backend.Repo
|
||
|
|
||
|
@impl true
|
||
|
def stream(schema) do
|
||
|
Repo.stream(schema)
|
||
|
end
|
||
|
|
||
|
@impl true
|
||
|
def transaction(fun) do
|
||
|
{:ok, result} = Repo.transaction(fun, timeout: :infinity)
|
||
|
result
|
||
|
end
|
||
|
end
|