lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
Subject custom sorting of search result
Date Mon, 03 Nov 2014 23:07:18 GMT

We need to order solr search results according to specific rules. 

I will explain with an example. Let say solr returns 1000 results for query "sport". 
These results must be divided into three buckets according to rules that come from database.

Then one doc must be chosen from each bucket and put in the results subsequently until all
buckets are empty.

One approach was to modify/override solr code where it gets results, sorts them and return
#rows of elements.
However, from the code in scoreAll function we see that docs have only internal
document id and nothing else. 

We expect unique solr document id in order to match documents with the custom scoring.
We also  see that Lucene code handles those doc ids to scoreAll function, and for now We do
not want to modify Lucene code
 and prefer to solve this issue as a Solr  plugin .

Any ideas are welcome.


  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message