curl -v es1:9200/versions-index/documents/_search?pretty\&q=_id:jnsjir2019-fg-1455041\\!02fd15d1e2649c95027b8548f42c0e7d > es.out
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0* Trying 10.15.19.174...
* TCP_NODELAY set
* Connected to es1 (10.15.19.174) port 9200 (#0)
> GET /versions-index/documents/_search?pretty&q=_id:jnsjir2019-fg-1455041\!02fd15d1e2649c95027b8548f42c0e7d HTTP/1.1
> Host: es1:9200
> User-Agent: curl/7.61.1
> Accept: */*
>
< HTTP/1.1 200 OK
< Content-Type: application/json; charset=UTF-8
< Content-Length: 16701
<
{ [16701 bytes data]
100 16701 100 16701 0 0 5436k 0 --:--:-- --:--:-- --:--:-- 5436k
* Connection #0 to host es1 left intact
Above is the curl that reasonably works (using the query). Below are the results of that query.
{
"took" : 2,
"timed_out" : false,
"_shards" : {
"total" : 1,
"successful" : 1,
"failed" : 0
},
"hits" : {
"total" : 1,
"max_score" : 1.0,
"hits" : [ {
"_index" : "versions-index-v2-20160313",
"_type" : "documents",
"_id" : "jnsjir2019-fg-1455041!02fd15d1e2649c95027b8548f42c0e7d",
"_score" : 1.0,
"_routing" : "JNSJIR2019-FG-1455041",
"_source" : {
"admin" : {
"id" : "02fd15d1e2649c95027b8548f42c0e7d",
"grouping_id" : "jnsjir2019-fg-1455041!02fd15d1e2649c95027b8548f42c0e7d",
"an" : "JNSJIR2019-FG-1455041",
"index_date" : "2019-01-09T18:18:17.074Z",
"version" : 1546992000000,
"recalled" : false
},
"date" : {
"published" : "2019-01-09T00:00:00.000Z",
"modified" : "2019-01-09T00:00:00.000Z"
},
"has_media" : {
"abstract" : false,
"audio" : false,
"full_text" : true,
"image" : true,
"video" : false
},
"language" : {
"iso6391" : [ "en" ],
"iso6393" : [ "eng" ],
"auto" : [ "eng" ],
"freeform" : [ "English" ]
},
"publication" : {
"value" : "John's Review",
"volume" : "031/002"
}
},
"doctype" : {
"value" : "Article"
},
"format" : [ "html" ]
}
} ]
}
}
While that query works, going just by ID does not:
curl -v es1:9200/versions-index/documents/jnsjir2019-fg-1455041\!02fd15d1e2649c95027b8548f42c0e7d?pretty > tmp.out
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
0 0 0 0 0 0 0 0 --:--:-- --:--:-- --:--:-- 0* Trying 10.15.19.174...
* TCP_NODELAY set
* Connected to es1 (10.15.19.174) port 9200 (#0)
> GET /versions-index/documents/jnsjir2019-fg-1455041!02fd15d1e2649c95027b8548f42c0e7d?pretty HTTP/1.1
> Host: es1:9200
> User-Agent: curl/7.61.1
> Accept: */*
>
< HTTP/1.1 404 Not Found
< Content-Type: application/json; charset=UTF-8
< Content-Length: 135
<
response body is:
{
"_index" : "versions-index-v2-20160313",
"_type" : "documents",
"_id" : jnsjir2019-fg-1455041!02fd15d1e2649c95027b8548f42c0e7d,
"found" : false
}