forked from aparo/pyes
-
Notifications
You must be signed in to change notification settings - Fork 4
/
FAQ
35 lines (21 loc) · 810 Bytes
/
FAQ
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
.. _faq:
============================
Frequently Asked Questions
============================
.. contents::
:local:
.. _faq-general:
General
=======
.. _faq-when-to-use:
What connection type should I use?
----------------------------------
For general usage I suggest to use HTTP connection versus your server.
For more fast performance, mainly in indexing, I suggest to use thrift because its latency is lower.
How you can return a plain dict from a resultset?
=================================================
ResultSet iterates on ElasticSearchModel by default, to change this behaviour you need to pass a an object that
receive a connection and a dict object.
To return plain dict object, you must pass to the search call a model parameter:
.. code-block:: python
model=lambda x,y:y