I'm reading about partial updates and found that we cannot use external version with partial updates. However, I see that ES has introduced
primary_term for concurrency control. I see that
seq_no is automatically incremented with every change but I cannot set it myself. Is there a way to set custom value for
primary_term for partial updates?
The update API supports
if_primary_term parameters for optimistic concurrency control. See https://www.elastic.co/guide/en/elasticsearch/reference/current/docs-update.html
Is. that what you are after?
Thanks for the reply Alexander. I have looked at the Update API which supports both
if_primary_term, however, it appears that Elasticsearch sets these values and as a user we don't have an option to update these values. For instance, let's say this is what I get for a
For the update API, I have to set
if_seq_no to 10 and
_primary_term to 1, otherwise I get a
version_conflict_engine_exception. Note that I'm using
external_version too, which I cannot use for partial update.
However, I want to send my custom
seq_no. Let's say I want both
version to be the same.
This request also fails with
version_conflict_engine_exception. I was wondering if we can supply external version for
This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.