Closed
Description
Hello,
It seems that findAllById
method on CRUD Repository (implemented in SimpleElasticsearchRepository
) do not take iterable parameter size to search by IDs.
If passing more than 10 ids in iterable, Elasticsearch will return only first 10 results because of generated query :
{
"query": {
"ids": {
"values": [
"a030900000E9eSSAAZ",
"a030900000E9eLPAAZ",
"a030900000E9artAAB",
"a030900000E9abWAAR",
"a030900000BubyVAAR",
"a030900000EAUCwAAP",
"a030900000E9apzAAB",
"a030900000E9hNYAAZ",
"a030900000EABUFAA5",
"a030900000EABQpAAP",
"a030900000E9azSAAR",
"a030900000EAUDKAA5",
"a030900000EArpaAAD",
"a030900000E9apzAAB",
"a030900000E9apQAAR",
"a030900000FwfWRAAZ",
"a030900000E9eLPAAZ",
"a030900000EARdSAAX",
"a030900000E9h6SAAR",
"a030900000EAflkAAD"
]
}
}
}
I have a total response ok (size of iterable) but not hits (size of 10 default size).
I workaround it by doing a getById for each element, but not really performant :D