A soft commit does not control merging. The IndexWriter controls merging and hard commits go through the IndexWriter. A soft commit tells Solr to try and open a new SolrIndexSearcher with the latest view of the index. It does this with a mix of using the on disk index and talking to the IndexWriter to see updates that have not been committed.
Opening a new SolrIndexSearcher using the IndexWriter this way does have a cost. You may flush segments, you may apply deletes, you may have to rebuild partial or full in memory data structures. It's generally much faster than a hard commit to get a refreshed view of the index though. Given how SolrCloud was designed, it's usually best to set an auto hard commit to something that works for you, given how large it will make tlogs (affecting recovery times), and how much RAM is used. Then use soft commits for visibility. It's best to use them as infrequently as your use case allows. - Mark On Thu, May 10, 2018 at 10:49 AM Shivam Omar <shivam.o...@jeevansathi.com> wrote: > Hi, > > I need some help in understanding solr soft commits. As soft commits are > about visibility and are fast in nature. They are advised for nrt use > cases. I want to understand does soft commit also honor merge policies and > do segment merging for docs in memory. For example, in case, I keep hard > commit interval very high and allow few million documents to be in memory > by using soft commit with no hard commit, can it affect solr query time > performance. > > > Shivam > > Get Outlook for Android<https://aka.ms/ghei36> > > DISCLAIMER > This email and any files transmitted with it are intended solely for the > person or the entity to whom they are addressed and may contain information > which is Confidential and Privileged. Any misuse of the information > contained in this email, including but not limited to retransmission or > dissemination of the said information by person or entities other than the > intended recipient is unauthorized and strictly prohibited. If you are not > the intended recipient of this email, please delete this email and contact > the sender immediately. > -- - Mark about.me/markrmiller