If I want to retrieve documents by id, which one is preferred?
term query by id
get api
Provided that performance is the first priority and I do not need to
retrieve by "real time", i.e. the freshness of the documents retrieved
can be the same as normal search.
Get api seems to be more preferred as it can be specified as "local",
but is the term query by id faster if the documents somehow is
"cached" internally?
On Tue, 2012-06-26 at 00:18 +0800, Yiu Wing TSANG wrote:
If I want to retrieve documents by id, which one is preferred?
term query by id
get api
Provided that performance is the first priority and I do not need to
retrieve by "real time", i.e. the freshness of the documents retrieved
can be the same as normal search.
Get api seems to be more preferred as it can be specified as "local",
but is the term query by id faster if the documents somehow is
"cached" internally?
The GET api will definitely be faster than the term query
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.