Also, is it possible that the default order for an equal relevance score
changed between 1.0 and 1.2 ? We've noticed seemingly random ordering in
our regression when updating.
On Wednesday, 14 May 2014 00:49:55 UTC, Erich Lin wrote:
Ignoring the bouncing results problem with multiple shards , is the order
of results deterministic when sorting by relevance score or any other
field.
What I mean by this is if two documents have the same score,
will they always be in the same order if we set the preference
parameter to an arbitrary string like the user’s session ID.
If so, is there a way to predict this deterministic order? Is it done
by ID of the documents as a tiebreaker etc?
If not, could we specify that or do we have to do a secondary sort on
ID if we wanted to do that?
Also, is it possible that it changed between versions 1.0 and 1.2? We're
trying to upgrade and noticed a seemingly random order of documents with
equal relevance in regression testing.
On Wednesday, 14 May 2014 00:49:55 UTC, Erich Lin wrote:
Ignoring the bouncing results problem with multiple shards , is the order
of results deterministic when sorting by relevance score or any other
field.
What I mean by this is if two documents have the same score,
will they always be in the same order if we set the preference
parameter to an arbitrary string like the user’s session ID.
If so, is there a way to predict this deterministic order? Is it done
by ID of the documents as a tiebreaker etc?
If not, could we specify that or do we have to do a secondary sort on
ID if we wanted to do that?
will they always be in the same order if we set the preference
parameter to an arbitrary string like the user’s session ID.
They will be, until a merge happens (eg from indexing, updating, deleting,
or just because...)
If so, is there a way to predict this deterministic order? Is it done
by ID of the documents as a tiebreaker etc?
It's the order of docs in the Lucene segment
If not, could we specify that or do we have to do a secondary sort on
ID if we wanted to do that?
Yes, you could provide a secondary sort on _uid (not _id)
Also, is it possible that the default order for an equal relevance score
changed between 1.0 and 1.2 ? We've noticed seemingly random ordering in
our regression when updating.
It shouldn't have - if you can reproduce this, please open an issue.
Apache, Apache Lucene, Apache Hadoop, Hadoop, HDFS and the yellow elephant
logo are trademarks of the
Apache Software Foundation
in the United States and/or other countries.