You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@solr.apache.org by "Saur, Alexandre (ELS-AMS)" <a....@elsevier.com> on 2021/10/12 12:59:10 UTC

Solr 8 autocommit vs client commits

Sorry for the noobie question guys, but I want to make sure I understand the autocommit behaviour in Solr 8.

Supposing I have an autocommit time of 5 minutes for a collection A, and that collection has one pending document to index. If a client (solrj.SolrClient) connects and adds a new document with the commitWithinMs parameter set (e.g. 30 sec), what happens after the client call? Specifically, will the pending document get committed as well and the index will have those 2 documents added, or just the document added in the client call?


________________________________

Elsevier B.V. Registered Office: Radarweg 29, 1043 NX Amsterdam, The Netherlands, Registration No. 33158992, Registered in The Netherlands.

Re: Solr 8 autocommit vs client commits

Posted by dinesh naik <di...@gmail.com>.
Hi Saur,
Yes , if you commit from a client with time set as 30 sec then the pending
docs will also get committed in solr.

Sending explicit commit requests from client applications should be avoided
as it can severely impact the performance of your clusters.

Solr provides IgnoreCommitOptimizeUpdateProcessorFactory, which will ignore
all explicit commits/optimize .This change can be done in solrconfig.xml.

for more details on commit, you can refer:
https://lucidworks.com/post/understanding-transaction-logs-softcommit-and-commit-in-sorlcloud/


On Tue, Oct 12, 2021 at 6:29 PM Saur, Alexandre (ELS-AMS) <
a.saur@elsevier.com> wrote:

> Sorry for the noobie question guys, but I want to make sure I understand
> the autocommit behaviour in Solr 8.
>
> Supposing I have an autocommit time of 5 minutes for a collection A, and
> that collection has one pending document to index. If a client
> (solrj.SolrClient) connects and adds a new document with the commitWithinMs
> parameter set (e.g. 30 sec), what happens after the client call?
> Specifically, will the pending document get committed as well and the index
> will have those 2 documents added, or just the document added in the client
> call?
>
>
> ________________________________
>
> Elsevier B.V. Registered Office: Radarweg 29, 1043 NX Amsterdam, The
> Netherlands, Registration No. 33158992, Registered in The Netherlands.
>


-- 
Best Regards,
Dinesh Naik

Re: Solr 8 autocommit vs client commits

Posted by Shankar R <ia...@gmail.com>.
Yes they will get committed as well. Commutwithin takes highest priority

On Tue, Oct 12, 2021, 6:29 PM Saur, Alexandre (ELS-AMS) <a....@elsevier.com>
wrote:

> Sorry for the noobie question guys, but I want to make sure I understand
> the autocommit behaviour in Solr 8.
>
> Supposing I have an autocommit time of 5 minutes for a collection A, and
> that collection has one pending document to index. If a client
> (solrj.SolrClient) connects and adds a new document with the commitWithinMs
> parameter set (e.g. 30 sec), what happens after the client call?
> Specifically, will the pending document get committed as well and the index
> will have those 2 documents added, or just the document added in the client
> call?
>
>
> ________________________________
>
> Elsevier B.V. Registered Office: Radarweg 29, 1043 NX Amsterdam, The
> Netherlands, Registration No. 33158992, Registered in The Netherlands.
>