From 6a7a77eada001f66c678f2b6bef65227e16ea6a1 Mon Sep 17 00:00:00 2001 From: Clinton Gormley Date: Fri, 18 Jul 2014 13:55:20 +0200 Subject: [PATCH] Docs: Add links to client helper classes for bulk/scroll/reindexing --- docs/reference/docs/bulk.asciidoc | 24 ++++++++++++++++--- docs/reference/search/request/scroll.asciidoc | 17 +++++++++++++ 2 files changed, 38 insertions(+), 3 deletions(-) diff --git a/docs/reference/docs/bulk.asciidoc b/docs/reference/docs/bulk.asciidoc index 5dde50ec3d8..36d77c97157 100644 --- a/docs/reference/docs/bulk.asciidoc +++ b/docs/reference/docs/bulk.asciidoc @@ -2,8 +2,26 @@ == Bulk API The bulk API makes it possible to perform many index/delete operations -in a single API call. This can greatly increase the indexing speed. The -REST API endpoint is `/_bulk`, and it expects the following JSON +in a single API call. This can greatly increase the indexing speed. + +.Client support for bulk requests +********************************************* + +Some of the officially supported clients provide helpers to assist with +bulk requests and reindexing of documents from one index to another: + +Perl:: + + See https://metacpan.org/pod/Search::Elasticsearch::Bulk[Search::Elasticsearch::Bulk] + and https://metacpan.org/pod/Search::Elasticsearch::Scroll[Search::Elasticsearch::Scroll] + +Python:: + + See http://elasticsearch-py.readthedocs.org/en/master/helpers.html[elasticsearch.helpers.*] + +********************************************* + +The REST API endpoint is `/_bulk`, and it expects the following JSON structure: [source,js] @@ -19,7 +37,7 @@ optional_source\n *NOTE*: the final line of data must end with a newline character `\n`. -The possible actions are `index`, `create`, `delete` and `update`. +The possible actions are `index`, `create`, `delete` and `update`. `index` and `create` expect a source on the next line, and have the same semantics as the `op_type` parameter to the standard index API (i.e. create will fail if a document with the same diff --git a/docs/reference/search/request/scroll.asciidoc b/docs/reference/search/request/scroll.asciidoc index 87ce87962cc..d71b7bec54d 100644 --- a/docs/reference/search/request/scroll.asciidoc +++ b/docs/reference/search/request/scroll.asciidoc @@ -10,6 +10,23 @@ Scrolling is not intended for real time user requests, but rather for processing large amounts of data, e.g. in order to reindex the contents of one index into a new index with a different configuration. +.Client support for scrolling and reindexing +********************************************* + +Some of the officially supported clients provide helpers to assist with +scrolled searches and reindexing of documents from one index to another: + +Perl:: + + See https://metacpan.org/pod/Search::Elasticsearch::Bulk[Search::Elasticsearch::Bulk] + and https://metacpan.org/pod/Search::Elasticsearch::Scroll[Search::Elasticsearch::Scroll] + +Python:: + + See http://elasticsearch-py.readthedocs.org/en/master/helpers.html[elasticsearch.helpers.*] + +********************************************* + NOTE: The results that are returned from a scroll request reflect the state of the index at the time that the initial `search` request was made, like a snapshot in time. Subsequent changes to documents (index, update or delete)