kafka-connect-elasticsearch icon indicating copy to clipboard operation
kafka-connect-elasticsearch copied to clipboard

Ignoring version conflict for "operation" INDEX on document

Open izzie88 opened this issue 4 years ago • 4 comments

Hi,

I keep getting the error "WARN || Ignoring version conflict for operation INDEX on document version -1 in index" on one of my topics. I use the same settings with other topics on kafka connect but i dont get the error.

I don't know what the issue might be.

Please help

izzie88 avatar Feb 24 '21 21:02 izzie88

I see the same on my instance. This issue seems to explain the problem, but unfortunately no solution is provided: https://github.com/confluentinc/kafka-connect-elasticsearch/issues/485

tporeba avatar Sep 02 '21 12:09 tporeba

we do not have solution how to solve this or any suggestion how to avoid this issue ?

ramyogi7283 avatar Jul 24 '23 15:07 ramyogi7283

Yes, expected behaviour must be to replace the document with tghe same id rather than throwing error. This is I think critical

oneryalcin avatar Aug 15 '23 10:08 oneryalcin

write.method=UPSERT works find for not sending version external. But as per the code. DELETE still sends version so it is causing the DELETE ignoring issue. when record value NULL. I am confused this logic. How to avoid DELETE with EXTERNAL version send and if change UPSERT then again index or updating documents causing issue.

final String id = config.shouldIgnoreKey(record.topic())
    ? String.format("%s+%d+%d", record.topic(), record.kafkaPartition(), record.kafkaOffset())
    : convertKey(record.keySchema(), record.key());

// delete
if (record.value() == null) {
  return maybeAddExternalVersioning(new DeleteRequest(index).id(id), record);
}

ramyogi7283 avatar Sep 08 '23 16:09 ramyogi7283