Understanding Query-DSL parameters
query
: Thequery
object contains all the queries that need to be passed to Elasticsearch. For example, the query to find all the documents that belong to a search category can written as follows:GET index_name/doc_type/_search { "query": { "query_string": { "default_field": "category", "query": "search" } } }
from
andsize
: These parameters control the pagination and the result size to be returned after querying. Thefrom
parameter is used to specify the starting point from which document the results will be returned. It defaults to0
. Thesize
parameter, which defaults to10
, specifies how many top documents will be returned from the total matched documents in a corpus._source
: This is an optional parameter that ...
Get Elasticsearch Essentials now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.