jpountz commented on a change in pull request #1294: LUCENE-9074: Slice Allocation Control Plane For Concurrent Searches URL: https://github.com/apache/lucene-solr/pull/1294#discussion_r401583032
########## File path: lucene/core/src/java/org/apache/lucene/search/IndexSearcher.java ########## @@ -208,9 +210,21 @@ public IndexSearcher(IndexReader r, Executor executor) { * @lucene.experimental */ public IndexSearcher(IndexReaderContext context, Executor executor) { + this(context, executor, getSliceExecutionControlPlane(executor)); + } + + // Package private for testing + IndexSearcher(IndexReaderContext context, Executor executor, SliceExecutor sliceExecutor) { assert context.isTopLevel: "IndexSearcher's ReaderContext must be topLevel for reader" + context.reader(); + if (executor == null) { + assert sliceExecutor == null; + } Review comment: this is covered by the below assert already? ---------------------------------------------------------------- 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. For queries about this service, please contact Infrastructure at: us...@infra.apache.org With regards, Apache Git Services --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org For additional commands, e-mail: issues-h...@lucene.apache.org