# Errors on delete from CouchDB river

**URL:** <https://discuss.elastic.co/t/errors-on-delete-from-couchdb-river/6291>\
**Category:** Elasticsearch\
**Created:** [January 5, 2012, 6:06am UTC](https://discuss.elastic.co/t/errors-on-delete-from-couchdb-river/6291 "2012-01-05T06:06:44Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![Dan\_Everton](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dan_everton/32/1865_2.png) [@Dan\_Everton](https://discuss.elastic.co/u/Dan_Everton)\
**Post date:** [January 5, 2012, 6:06am UTC](https://discuss.elastic.co/t/errors-on-delete-from-couchdb-river/6291/1 "2012-01-05T06:06:44Z")

</div>

Getting a stack trace from Elasticsearch when ever it processes a  
delete from a CouchDB river. See [https://gist.github.com/1563960](https://gist.github.com/1563960)

ES seems to be complaining about a version mismatch, but I can't  
figure out why.

---

<div class="post-metadata">

**Author:** ![kimchy](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/kimchy/32/44952_2.png) [@kimchy](https://discuss.elastic.co/u/kimchy)\
**Post date:** [January 5, 2012, 1:43pm UTC](https://discuss.elastic.co/t/errors-on-delete-from-couchdb-river/6291/2 "2012-01-05T13:43:56Z")

</div>

It means that it tried to delete a document that does not exists in  
elasticsearch.

On Thu, Jan 5, 2012 at 8:06 AM, Dan Everton [dan@iocaine.org](mailto:dan@iocaine.org) wrote:

> Getting a stack trace from Elasticsearch when ever it processes a  
> delete from a CouchDB river. See [Stack trace on delete in Elasticsearch · GitHub](https://gist.github.com/1563960)
> 
> ES seems to be complaining about a version mismatch, but I can't  
> figure out why.

---

<div class="post-metadata">

**Author:** ![Dan\_Everton](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dan_everton/32/1865_2.png) [@Dan\_Everton](https://discuss.elastic.co/u/Dan_Everton)\
**Post date:** [January 5, 2012, 9:43pm UTC](https://discuss.elastic.co/t/errors-on-delete-from-couchdb-river/6291/3 "2012-01-05T21:43:56Z")

</div>

On Jan 5, 11:43 pm, Shay Banon [kim...@gmail.com](mailto:kim...@gmail.com) wrote:

> It means that it tried to delete a document that does not exists in  
> elasticsearch.

So the next question: is that a problem and is there a way to maybe  
suppress that error in this case?

I'm trying to work around the delete event from CouchDB not including  
the original document by creating a river for each type of document in  
the database. The end result is that all the rivers will get the same  
delete event, but only one of them will succeed.

---

<div class="post-metadata">

**Author:** ![Dan\_Everton](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dan_everton/32/1865_2.png) [@Dan\_Everton](https://discuss.elastic.co/u/Dan_Everton)\
**Post date:** [January 5, 2012, 10:17pm UTC](https://discuss.elastic.co/t/errors-on-delete-from-couchdb-river/6291/4 "2012-01-05T22:17:24Z")

</div>

Hrm, actually, maybe it's more complicated than that. The document  
being deleted is a child document but since I can't know the parent ID  
the routing isn't getting set for the delete. Would this be why I get  
the error? The document does exist prior to the delete.

---

<div class="post-metadata">

**Author:** ![kimchy](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/kimchy/32/44952_2.png) [@kimchy](https://discuss.elastic.co/u/kimchy)\
**Post date:** [January 5, 2012, 10:25pm UTC](https://discuss.elastic.co/t/errors-on-delete-from-couchdb-river/6291/5 "2012-01-05T22:25:33Z")

</div>

Yes, it sounds like this might be the case, as the document is not routed  
to the shard it exists on.

On Fri, Jan 6, 2012 at 12:17 AM, Dan Everton [dan@iocaine.org](mailto:dan@iocaine.org) wrote:

> Hrm, actually, maybe it's more complicated than that. The document  
> being deleted is a child document but since I can't know the parent ID  
> the routing isn't getting set for the delete. Would this be why I get  
> the error? The document does exist prior to the delete.

---

<div class="post-metadata">

**Author:** ![Dan\_Everton](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/dan_everton/32/1865_2.png) [@Dan\_Everton](https://discuss.elastic.co/u/Dan_Everton)\
**Post date:** [January 6, 2012, 12:02am UTC](https://discuss.elastic.co/t/errors-on-delete-from-couchdb-river/6291/6 "2012-01-06T00:02:36Z")

</div>

Okay, so the delete is then routed to all shards and those that don't  
have the document log an error. The delete does actually work as in  
the document is gone from the index, but the error messages are a bit  
disconcerting. Is there a way to suppress the error logging in this  
case? I can set the 'action.bulk' category to be something higher than  
TRACE to suppress it, but that means we won't see other bulk errors.

---

<div class="post-metadata">

**Author:** ![kimchy](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/kimchy/32/44952_2.png) [@kimchy](https://discuss.elastic.co/u/kimchy)\
**Post date:** [January 6, 2012, 11:29am UTC](https://discuss.elastic.co/t/errors-on-delete-from-couchdb-river/6291/7 "2012-01-06T11:29:56Z")

</div>

In master those log messages are no longer logged.

On Fri, Jan 6, 2012 at 2:02 AM, Dan Everton [dan@iocaine.org](mailto:dan@iocaine.org) wrote:

> Okay, so the delete is then routed to all shards and those that don't  
> have the document log an error. The delete does actually work as in  
> the document is gone from the index, but the error messages are a bit  
> disconcerting. Is there a way to suppress the error logging in this  
> case? I can set the 'action.bulk' category to be something higher than  
> TRACE to suppress it, but that means we won't see other bulk errors.

---

<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:** [July 6, 2017, 3:43am UTC](https://discuss.elastic.co/t/errors-on-delete-from-couchdb-river/6291/8 "2017-07-06T03:43:41Z")

</div>


