Description
Elasticsearch version:2.3.1
JVM version:
java version "1.8.0_77"
Java(TM) SE Runtime Environment (build 1.8.0_77-b03)
Java HotSpot(TM) 64-Bit Server VM (build 25.77-b03, mixed mode)
OS version:
Linux customerhostname 3.10.0-327.10.1.el7.x86_64 #1 SMP Tue Feb 16 17:03:50 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux
Description of the problem including expected versus actual behavior: Following the documentation on https://www.elastic.co/guide/en/elasticsearch/reference/2.3/mapping-parent-field.html I get a 400 error in sense for the second PUT, following it in FireFox RestClient (using POST not GET as per https://www.elastic.co/guide/en/elasticsearch/reference/current/search-request-body.html), I get no results for the final has_child query.
Steps to reproduce:
- Install elastic, single node, default everything
- Apply mapping and add data as shown on https://www.elastic.co/guide/en/elasticsearch/reference/2.3/mapping-parent-field.html
- Issue query shown at https://www.elastic.co/guide/en/elasticsearch/reference/2.3/mapping-parent-field.html
Expected result: One my_parent document should be returned (even if further parent docs are added)...
Actual result: No documents are ever returned by any "has_child" query, including a match all query such as:
POST my_index/my_parent/_search?routing=_id
{
"query": {
"has_child": {
"type": "my_child",
"query": { "match_all": {} }
}
}
}
Running queries with a GET line in Sense (after posting the docs with RestClient due to aforementioned 400 error) also does not work.