ElasticsearchElixirBulkProcessor.Items.Index (Elasticsearch Elixir Bulk Processor v0.1.7)

Link to this section Summary

Functions

Examples

iex> %ElasticsearchElixirBulkProcessor.Items.Index{index: "test", source: %{"test" => "test"}} ...> |> ElasticsearchElixirBulkProcessor.Items.Index.to_payload() "{\"index\":{\"_index\":\"test\"}}\n{\"test\":\"test\"}"

Link to this section Functions

Link to this function

to_payload(item)

Examples

iex> %ElasticsearchElixirBulkProcessor.Items.Index{index: "test", source: %{"test" => "test"}} ...> |> ElasticsearchElixirBulkProcessor.Items.Index.to_payload() "{\"index\":{\"_index\":\"test\"}}\n{\"test\":\"test\"}"

iex> %ElasticsearchElixirBulkProcessor.Items.Index{index: "test", id: "1", source: %{"test" => "test"}} ...> |> ElasticsearchElixirBulkProcessor.Items.Index.to_payload() "{\"index\":{\"_index\":\"test\",\"_id\":\"1\"}}\n{\"test\":\"test\"}"