Elasticsearch Elixir Bulk Processor v0.0.2 ElasticsearchElixirBulkProcessor.Items.Create

Link to this section Summary

Functions

Examples

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

Link to this section Functions

Link to this function

to_payload(item)

Examples

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

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