View Source ElasticsearchEx (Elasticsearch_ex v1.8.3)

Provides some convenient functions.

Summary

Types

document_id()

@type document_id() :: binary()

index()

@type index() :: atom() | binary()

opts()

@type opts() :: keyword()

query()

@type query() :: map()

response()

@type response() :: {:ok, term()} | {:error, ElasticsearchEx.Error.t()}

source()

@type source() :: map()

Functions

index(source, index, document_id \\ nil, opts \\ [])

(since 1.0.0)
@spec index(source(), index(), nil | document_id(), keyword()) :: response()

Refer to ElasticsearchEx.API.Document.index/4 documentation.

search()

(since 1.5.0)
@spec search() :: response()

Refer to ElasticsearchEx.API.Search.search/0 documentation.

search(query_or_index_or_opts)

(since 1.5.0)
@spec search(query() | index() | opts()) :: response()

Refer to ElasticsearchEx.API.Search.search/1 documentation.

search(query_or_index, index_or_opts)

(since 1.5.0)
@spec search(query() | index(), index() | opts()) :: response()

Refer to ElasticsearchEx.API.Search.search/2 documentation.

search(query, index, opts)

(since 1.0.0)
@spec search(query(), index(), keyword()) :: response()

Refer to ElasticsearchEx.API.Search.search/3 documentation.

stream(query, index \\ nil, opts \\ [])

(since 1.3.0)
@spec stream(query(), nil | index(), keyword()) :: Enumerable.t()

Refer to ElasticsearchEx.API.Search.search/2 documentation.