Hi guys,
First off all, I would like to say hi to all of you and ask if you are enjoying the rainy days right now too.
The second thing is our Elasticsearch version:
curl -XGET 'localhost:9100'
{
"ok" : true,
"status" : 200,
"name" : "Autolycus",
"version" : {
"number" : "0.90.13",
"build_hash" : "249c9c5e06765c9e929e92b1d235e1ba4dc679fa",
"build_timestamp" : "2014-03-25T15:27:12Z",
"build_snapshot" : false,
"lucene_version" : "4.6"
},
"tagline" : "You Know, for Search"
}
Overall, our system works pretty well, but there is a problem with few specific documents and search queries.
The annotation mapping looks like this:
"1212" : {
"annotation" : {
"properties" : {
"caseNumber" : {
"type" : "integer"
},
"content" : {
"type" : "string",
"analyzer" : "ninstitution"
},
"institutionId" : {
"type" : "string"
},
"departmentId" : {
"type" : "string"
},
"person" : {
"type" : "string",
"analyzer" : "ninstitution"
},
"protocol" : {
"type" : "boolean"
},
"protocolId" : {
"type" : "string"
},
"timeOffset" : {
"type" : "long"
},
"year" : {
"type" : "integer"
}
}
}
}
The thing, which I cannot understand is why I get the same results for the two completely different queries:
curl -XGET 'http://localhost:9100/1212/_search?pretty=true' -d '{"size" : 1000,
"query" : {
"bool" : {
"must" : [ {
"field" : {
"protocolId" : "121210250002027_1043_12_Kor-716_20160516_080329"
}
}, {
"field" : {
"protocol" : true
}
} ]
}
},
"sort" : [ {
"timeOffset" : {
"order" : "asc"
}
} ]
}'
curl -XGET 'http://localhost:9100/1212/_search?pretty=true' -d '{"size" : 1000,
"query" : {
"bool" : {
"must" : [ {
"field" : {
"protocolId" : "121210250002027_1043_12_Kor-708_20160801_094045"
}
}, {
"field" : {
"protocol" : true
}
} ]
}
},
"sort" : [ {
"timeOffset" : {
"order" : "asc"
}
} ]
}'
Do you have an idea how to debug this problem? I removed the returned documents by hand (via curl -XDELETE) and then added them again, but it looks that somehow they manage to connect to the two protocolIds:
- 121210250002027_1043_12_Kor-708_20160801_094045
- 121210250002027_1043_12_Kor-716_20160516_080329
Maybe some kind of hashing returns the same values for the forementioned pair? Is that possible?
PS: I changed the ids I little bit, so these two are only the example.