In a word, “no”. There is explicit code to _not_ open a new searcher if the index hasn’t changed because it’s an expensive operation.
Could you explain _why_ you want to open a new searcher even though the index is unchanged? The reason for the check in the first place is that nothing has changed about the index so the assumption is that there’s no reason to open a new searcher. You could add at least one bogus doc on each shard, then delete them all then issue a commit as a rather crude way to do this. Insuring that you changed at least one doc on each shard is “an exercise for the reader”… Again, though, perhaps if you explained why you think this is necessary we could suggest another approach. At first glance, this looks like an XY problem though. Best, Erick > On Aug 10, 2020, at 5:49 AM, Akshay Murarka <aks...@saavn.com> wrote: > > Hey, > > I have a use case where none of the document in my solr index is changing but > I still want to open a new searcher through the curl api. > On executing the below curl command > curl > “XXX.XX.XX.XXX:9744/solr/mycollection/update?openSearcher=true&commit=true” > it doesn’t open a new searcher. Below is what I get in logs > > 2020-08-10 09:32:22.696 INFO (qtp297786644-6824) [c:mycollection > s:shard1_1_0 r:core_node6 x:mycollection_shard1_1_0_replica1] > o.a.s.u.DirectUpdateHandler2 start > commit{,optimize=false,openSearcher=true,waitSearcher=true,expungeDeletes=false,softCommit=false,prepareCommit=false} > 2020-08-10 09:32:22.696 INFO (qtp297786644-6819) [c:mycollection > s:shard1_0_1 r:core_node5 x:mycollection_shard1_0_1_replica1] > o.a.s.u.DirectUpdateHandler2 start > commit{,optimize=false,openSearcher=true,waitSearcher=true,expungeDeletes=false,softCommit=false,prepareCommit=false} > 2020-08-10 09:32:22.696 INFO (qtp297786644-6829) [c:mycollection > s:shard1_0_0 r:core_node4 x:mycollection_shard1_0_0_replica1] > o.a.s.u.DirectUpdateHandler2 start > commit{,optimize=false,openSearcher=true,waitSearcher=true,expungeDeletes=false,softCommit=false,prepareCommit=false} > 2020-08-10 09:32:22.696 INFO (qtp297786644-6824) [c:mycollection > s:shard1_1_0 r:core_node6 x:mycollection_shard1_1_0_replica1] > o.a.s.u.DirectUpdateHandler2 No uncommitted changes. Skipping IW.commit. > 2020-08-10 09:32:22.696 INFO (qtp297786644-6819) [c:mycollection > s:shard1_0_1 r:core_node5 x:mycollection_shard1_0_1_replica1] > o.a.s.u.DirectUpdateHandler2 No uncommitted changes. Skipping IW.commit. > 2020-08-10 09:32:22.696 INFO (qtp297786644-6766) [c:mycollection > s:shard1_1_1 r:core_node7 x:mycollection_shard1_1_1_replica1] > o.a.s.u.DirectUpdateHandler2 start > commit{,optimize=false,openSearcher=true,waitSearcher=true,expungeDeletes=false,softCommit=false,prepareCommit=false} > 2020-08-10 09:32:22.696 INFO (qtp297786644-6829) [c:mycollection > s:shard1_0_0 r:core_node4 x:mycollection_shard1_0_0_replica1] > o.a.s.u.DirectUpdateHandler2 No uncommitted changes. Skipping IW.commit. > 2020-08-10 09:32:22.696 INFO (qtp297786644-6766) [c:mycollection > s:shard1_1_1 r:core_node7 x:mycollection_shard1_1_1_replica1] > o.a.s.u.DirectUpdateHandler2 No uncommitted changes. Skipping IW.commit. > 2020-08-10 09:32:22.697 INFO (qtp297786644-6824) [c:mycollection > s:shard1_1_0 r:core_node6 x:mycollection_shard1_1_0_replica1] > o.a.s.c.SolrCore SolrIndexSearcher has not changed - not re-opening: > org.apache.solr.search.SolrIndexSearcher > 2020-08-10 09:32:22.697 INFO (qtp297786644-6819) [c:mycollection > s:shard1_0_1 r:core_node5 x:mycollection_shard1_0_1_replica1] > o.a.s.c.SolrCore SolrIndexSearcher has not changed - not re-opening: > org.apache.solr.search.SolrIndexSearcher > 2020-08-10 09:32:22.697 INFO (qtp297786644-6829) [c:mycollection > s:shard1_0_0 r:core_node4 x:mycollection_shard1_0_0_replica1] > o.a.s.c.SolrCore SolrIndexSearcher has not changed - not re-opening: > org.apache.solr.search.SolrIndexSearcher > 2020-08-10 09:32:22.697 INFO (qtp297786644-6824) [c:mycollection > s:shard1_1_0 r:core_node6 x:mycollection_shard1_1_0_replica1] > o.a.s.u.DirectUpdateHandler2 end_commit_flush > 2020-08-10 09:32:22.697 INFO (qtp297786644-6819) [c:mycollection > s:shard1_0_1 r:core_node5 x:mycollection_shard1_0_1_replica1] > o.a.s.u.DirectUpdateHandler2 end_commit_flush > 2020-08-10 09:32:22.697 INFO (qtp297786644-6829) [c:mycollection > s:shard1_0_0 r:core_node4 x:mycollection_shard1_0_0_replica1] > o.a.s.u.DirectUpdateHandler2 end_commit_flush > > > I don’t want to do a complete reload of my collection. > Is there any parameter that can be used to forcefully open a new searcher > every time I do a commit with openSearcher=true > > Thanks in advance for the help >