lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jamie Johnson <>
Subject Using payloads and user provided data in score
Date Wed, 22 Jul 2015 19:21:25 GMT
I am looking for a way to prevent fields that users shouldn't be able to
know exist from contributing to the score.  The goal is to provide a way to
essentially hide certain fields from requests based on an access level
provided on the query.  I have managed to make terms that users shouldn't
be able to see not impact the score by implementing a custom Similarity
class that looks at the terms payloads and returns 0 for the score if they
shouldn't know the field exists.  The issue however is that I don't have
access to the request at this point so getting the users access level is
proving problematic.  Is there a way to get the current request that is
being processed via some thread local variable or something similar that
Solr maintains?  If not is there another approach that I could be using to
access information from the request within my Similarity implementation?
Any thoughts on this would be greatly appreciated.


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