Add some docs for scan mentioning passing extra args to search

Fixes #186 Thanks jpshelley!
This commit is contained in:
Honza Král
2015-01-16 23:33:38 +01:00
parent 87bba04d4d
commit 32f23b6748
+8 -1
View File
@@ -172,7 +172,14 @@ def scan(client, query=None, scroll='5m', preserve_order=False, **kwargs):
unpredictable results, use with caution.
Any additional keyword arguments will be passed to the initial
:meth:`~elasticsearch.Elasticsearch.search` call.
:meth:`~elasticsearch.Elasticsearch.search` call::
scan(es,
query={"match": {"title": "python"}},
index="orders-*",
doc_type="books"
)
"""
if not preserve_order:
kwargs['search_type'] = 'scan'