On 9/12/2014 9:10 AM, Joshi, Shital wrote: > We're updating Solr cloud from a java process using UpdateRequest API. > > UpdateRequest req = new UpdateRequest(); > req.setResponseParser(new XMLResponseParser()); > req.setParam("_shard_", shard); > req.add(docs); > > We see too many searcher open errors in log and wondering if frequent updates > from java process are causing it. What commit policy gets used when > UpdateRequest Solr API is used? Is it opensearcher=true? How do we disable > it? > > This is from log file: > > [commitScheduler-16-thread-1] INFO org.apache.solr.update.UpdateHandler ? > start > commit{,optimize=false,openSearcher=true,waitSearcher=true,expungeDeletes=false,soft > Commit=true,prepareCommit=false}
There is no commit policy specifically for UpdateRequests. To Solr, they are simply HTTP calls to the /update handler. If you send a commit to Solr with SolrJ, the default will be openSearcher=true, but you can override it. If you are relying on autoCommit, the value of openSearcher will be what you define in autoCommit. An autoSoftCommit always opens a new searcher -- there would be no point to a soft commit without it. Thanks, Shawn