# Version\_conflict\_engine\_exception，help me

**URL:** https://discuss.elastic.co/t/version-conflict-engine-exception-help-me/312065
**Category:** Elasticsearch
**Created:** [August 14, 2022, 12:24pm UTC](https://discuss.elastic.co/t/version-conflict-engine-exception-help-me/312065 "2022-08-14T12:24:38Z")
**Posts on this page:** 3
**Page:** 1

<div class="post-metadata">

### Author: ![wangshouqi111](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/wangshouqi111/32/109623_2.png) [@wangshouqi111](https://discuss.elastic.co/u/wangshouqi111)
#### Post date: [August 14, 2022, 12:24pm UTC](https://discuss.elastic.co/t/version-conflict-engine-exception-help-me/312065/1 "2022-08-14T12:24:38Z")

</div>

### Elasticsearch Version

7.1.1  
client:

```auto
 public void index(List<PromoSkuInfoEsEntry> promoSkuInfoEsEntries) throws IOException {
        BulkRequest request = new BulkRequest();
        List<List<PromoSkuInfoEsEntry>> lists = Lists.partition(promoSkuInfoEsEntries, 5000);
        for (List<PromoSkuInfoEsEntry> list : lists) {
            for (PromoSkuInfoEsEntry promoSkuInfoEsEntry : list) {
                String jsonValue = objectMapper.writeValueAsString(promoSkuInfoEsEntry);
                String id = PromoGenerateIdUtil.getPromoSkuESId(promoSkuInfoEsEntry);
                UpdateRequest updateRequest = new UpdateRequest(xxx, id).routing(promoSkuInfoEsEntry.getSkuId());
                updateRequest.doc(jsonValue, XContentType.JSON);
                updateRequest.docAsUpsert(true);
                request.add(updateRequest);
            }
            BulkResponse bulk = newPromoRestHighLevelClient.bulk(request, RequestOptions.DEFAULT);
            checkBulkResponse(bulk);
        }
    }

```

client version:

`````auto
<dependency> 
       <groupId>org.elasticsearch.client</groupId> 
       <artifactId>elasticsearch-rest-high-level-client</artifactId> 
       <version>7.1.1</version> 
</dependency>````

err log：

`````

- Caused by: org.elasticsearch.ElasticsearchException: Elasticsearch exception [type=version\_conflict\_engine\_exception, reason=[1\_1449437083\_12352061\_2020616363]: version conflict, required seqNo [69120140], primary term [1]. current document has seqNo [103022466] and primary term [1]]
- at org.elasticsearch.ElasticsearchException.innerFromXContent(ElasticsearchException.java:491)
- at org.elasticsearch.ElasticsearchException.fromXContent(ElasticsearchException.java:402)
- at org.elasticsearch.action.bulk.BulkItemResponse.fromXContent(BulkItemResponse.java:139)
- at org.elasticsearch.action.bulk.BulkResponse.fromXContent(BulkResponse.java:199)
- at org.elasticsearch.client.RestHighLevelClient.parseEntity(RestHighLevelClient.java:1706)
- at org.elasticsearch.client.RestHighLevelClient.lambda$performRequestAndParseEntity$8(RestHighLevelClient.java:1374)
- at org.elasticsearch.client.RestHighLevelClient.internalPerformRequest(RestHighLevelClient.java:1450)
- at org.elasticsearch.client.RestHighLevelClient.performRequest(RestHighLevelClient.java:1403)
- at org.elasticsearch.client.RestHighLevelClient.performRequestAndParseEntity(RestHighLevelClient.java:1373)
- at org.elasticsearch.client.RestHighLevelClient.bulk(RestHighLevelClient.java:477)
- at com.jddj.promo.search.db.es.PromoSkuOperateEs.index(PromoSkuOperateEs.java:99)

```auto

```

---

<div class="post-metadata">

### Author: ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)
#### Post date: [August 14, 2022, 12:29pm UTC](https://discuss.elastic.co/t/version-conflict-engine-exception-help-me/312065/2 "2022-08-14T12:29:17Z")

</div>

Elasticsearch Version  
7.1 is [EOL](https://www.elastic.co/support/eol) and no longer supported. Please upgrade ASAP.

(This is an automated response from your friendly Elastic bot. Please report this post if you have any suggestions or concerns :elasticheart: )

---

<div class="post-metadata">

### Author: ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)
#### Post date: [September 11, 2022, 12:29pm UTC](https://discuss.elastic.co/t/version-conflict-engine-exception-help-me/312065/3 "2022-09-11T12:29:42Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
