Search 3

1-01-07. Search Lite

A GET is fairly simple—you get back the document that you ask for. Let’s try something a little more advanced, like a simple search!GET 은 상당히 간단하다. request하면 document를 받을 수 있다. 간단한 검색처럼, 약간 더 고급스러운 뭔가를 해 보자.The first search we will try is the simplest search possible. We will search for all employees, with this request:첫 번째 검색은 가능한 가장 단순한 검색이다. 아래의 request를 가지고, 모든 직원을 검색할 것이다.GET /megacorp/empl..

1-05-4. Search Lite

There are two forms of the search API: a "lite" query-string version that expects all its parameters to be passed in the query string, and the full request body version that expects a JSON request body and uses a rich search language called the query DSL.search API에는 두 가지 형식이 있다. 하나는 query-string 의 "아류(lite)" 버전이다. 이 버전은 모든 매개변수가 query string에 전달된다. 다른 하나는 full request body 버전이다. 이 버전은 JSON requ..

1-07-1. Empty Search

Let’s start with the simplest form of the search API, the empty search, which returns all documents in all indices:search API의 가장 간단한 형태인, empty search로 시작해 보자. 모든 indices의 모든 document를 반환한다.GET /_search {} COPY AS CURLVIEW IN SENSE 이것이 empty request body이다.Just as with a query-string search, you can search on one, many, or _all indices, and one, many, or all types:query-string 검색과 마찬가지로, 하나 이상 ..