boicehuang opened a new issue, #13318:
URL: https://github.com/apache/lucene/issues/13318

   ### Description
   
   
https://github.com/apache/lucene/blob/main/lucene/core/src/java/org/apache/lucene/search/LRUQueryCache.java#L747
   
   Can we use ReentrantReadWriteLock in `LRUQueryCache`  to allow concurrent 
cache reading, to improve query performance? Any help will be appreciated.
    
   I benchmarked this optimization by mocking some random LongPoint and 
querying them with PointInSetQuery with bool filter.
   
   doc count | field cardinality | query point | baseline QPS | candidate QPS | 
diff percentage
   -- | -- | -- | -- | -- | --
   30000000 | 10 | 1 | 2481 | 5102 | 105.6%
   30000000 | 1000000 | 1 | 6396 | 6596.48 |  3.1%
   
   I think this change can help filter queries that need to query 
low-cardinality fields. If it helps, I will submit a PR.
   


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org
For additional commands, e-mail: issues-h...@lucene.apache.org

Reply via email to