You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-user@lucene.apache.org by Ganesh M <mg...@live.in> on 2016/10/24 07:41:20 UTC

Transactions behaviour on Batch insert / update

Hi all,

We are planning to make use of batch update / insert of solr documents, with batch size of around 100 documents per batch.

Bit curious on how transactions are maintained per batch. I do knew SOLR is not meant for transaction based, but want to know whether SOLR is designed to throw error even if one document in batch fails due to issue in data or invalid fields.

In case of such errors, whether complete batch fails or only one specific document fails and we get error for that specific document.

Pls let me know how SOLR behaves.

Regards,
Ganesh

Re: Transactions behaviour on Batch insert / update

Posted by Mikhail Khludnev <mk...@apache.org>.
Hello Ganesh,
By default the half of batch fails.
https://lucene.apache.org/solr/6_2_1/solr-core/org/apache/solr/update/processor/TolerantUpdateProcessorFactory.html
can fail only certain problematic rows. FWIW, you can send delete for
uncommitted documents, it wipes them from ram buffer, that's how you can
rollback a failed batch.

On Mon, Oct 24, 2016 at 10:41 AM, Ganesh M <mg...@live.in> wrote:

> Hi all,
>
> We are planning to make use of batch update / insert of solr documents,
> with batch size of around 100 documents per batch.
>
> Bit curious on how transactions are maintained per batch. I do knew SOLR
> is not meant for transaction based, but want to know whether SOLR is
> designed to throw error even if one document in batch fails due to issue in
> data or invalid fields.
>
> In case of such errors, whether complete batch fails or only one specific
> document fails and we get error for that specific document.
>
> Pls let me know how SOLR behaves.
>
> Regards,
> Ganesh
>



-- 
Sincerely yours
Mikhail Khludnev