GET API doesn't return for some documents even if they exist

When I use filter query like this:
url: http://localhost:9200/index/type/_search/
{
"filter": {
"term": {
"_id": 53454353
}
}
}

Elasticsearch returns the document that has that id. However when I try to
fetch a specific document via GET API it returns:

url: http://localhost:9200/index/type/53454353/
{
_index: index
_type: type
_id: 53454353
exists: false
}

The "type" has a _parent field and I suspect that it might cause a problem
in GET API. Any suggestion?

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Specify the routing parameter set to the value of the parent for that
document.

curl -XGET 'http://localhost:9200/index/type/5345353?routing=123'

On Wed, Feb 20, 2013 at 4:29 PM, Burak Emre Kabakcı
emrekabakci@gmail.com wrote:

When I use filter query like this:
url: http://localhost:9200/index/type/_search/
{
"filter": {
"term": {
"_id": 53454353
}
}
}

Elasticsearch returns the document that has that id. However when I try to
fetch a specific document via GET API it returns:

url: http://localhost:9200/index/type/53454353/
{
_index: index
_type: type
_id: 53454353
exists: false
}

The "type" has a _parent field and I suspect that it might cause a problem
in GET API. Any suggestion?

--
You received this message because you are subscribed to the Google Groups
"elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an
email to elasticsearch+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

I was thinking specifying the routing field makes the query faster but it
seems I have to specify it to be able to use GET API. Thanks.

From Elasticsearch Platform — Find real-time answers at scale | Elastic

The above will get a tweet with id 1, but will be routed based on the
user. Note, issuing a get without the correct routing, will cause the
document not to be fetched

On Thursday, February 21, 2013 2:36:04 AM UTC+2, Matt Weber wrote:

Specify the routing parameter set to the value of the parent for that
document.

curl -XGET 'http://localhost:9200/index/type/5345353?routing=123'

On Wed, Feb 20, 2013 at 4:29 PM, Burak Emre Kabakcı
<emrek...@gmail.com <javascript:>> wrote:

When I use filter query like this:
url: http://localhost:9200/index/type/_search/
{
"filter": {
"term": {
"_id": 53454353
}
}
}

Elasticsearch returns the document that has that id. However when I try
to
fetch a specific document via GET API it returns:

url: http://localhost:9200/index/type/53454353/
{
_index: index
_type: type
_id: 53454353
exists: false
}

The "type" has a _parent field and I suspect that it might cause a
problem
in GET API. Any suggestion?

--
You received this message because you are subscribed to the Google
Groups
"elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send
an
email to elasticsearc...@googlegroups.com <javascript:>.
For more options, visit https://groups.google.com/groups/opt_out.

--
You received this message because you are subscribed to the Google Groups "elasticsearch" group.
To unsubscribe from this group and stop receiving emails from it, send an email to elasticsearch+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.