You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@couchdb.apache.org by "Sebastian Cohnen (JIRA)" <ji...@apache.org> on 2010/12/21 17:03:06 UTC

[jira] Created: (COUCHDB-993) Replication is crashing when changes feed was consumed

Replication is crashing when changes feed was consumed
------------------------------------------------------

                 Key: COUCHDB-993
                 URL: https://issues.apache.org/jira/browse/COUCHDB-993
             Project: CouchDB
          Issue Type: Bug
          Components: Replication
    Affects Versions: 1.0.1, 1.0.2
            Reporter: Sebastian Cohnen


Yesterday I hit a bug, where pull replication is dying which is resulting in a {exit,{json_encode,{bad_term,<0.133.0>}}} error (CouchDB is trying to encode a PID into JSON).

Adam and Paul had a look at this issue yesterday and they found the underlying issue: There was a missing clause catching the exit message when the changes feed was consumed and ibrowse closes the HTTP connection for that feed.

Adam wrote a quick patch yesterday, which I'll append here too (applies cleanly to 1.0.x at time of writing).

(Sorry for any inaccuracy, I only understood the issue partially)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Resolved: (COUCHDB-993) Replication is crashing when changes feed was consumed

Posted by "Adam Kocoloski (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/COUCHDB-993?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Adam Kocoloski resolved COUCHDB-993.
------------------------------------

       Resolution: Fixed
    Fix Version/s: 1.1
                   1.0.2

Applied to trunk, 1.1.x and 1.0.x.  Sebastian, the OOME you observed with this patch applied was eventually fixed in COUCHDB-968, right?

> Replication is crashing when changes feed was consumed
> ------------------------------------------------------
>
>                 Key: COUCHDB-993
>                 URL: https://issues.apache.org/jira/browse/COUCHDB-993
>             Project: CouchDB
>          Issue Type: Bug
>          Components: Replication
>    Affects Versions: 1.0.1, 1.0.2
>            Reporter: Sebastian Cohnen
>             Fix For: 1.0.2, 1.1
>
>         Attachments: couchdb-993.patch
>
>
> Yesterday I hit a bug, where pull replication is dying which is resulting in a {exit,{json_encode,{bad_term,<0.133.0>}}} error (CouchDB is trying to encode a PID into JSON).
> Adam and Paul had a look at this issue yesterday and they found the underlying issue: There was a missing clause catching the exit message when the changes feed was consumed and ibrowse closes the HTTP connection for that feed.
> Adam wrote a quick patch yesterday, which I'll append here too (applies cleanly to 1.0.x at time of writing).
> (Sorry for any inaccuracy, I only understood the issue partially)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] [Commented] (COUCHDB-993) Replication is crashing when changes feed was consumed

Posted by "Maxim L. (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/COUCHDB-993?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13029244#comment-13029244 ] 

Maxim L. commented on COUCHDB-993:
----------------------------------

Have the same problem with 1.1.0a1099688, and only over https
Patch is already applied

> Replication is crashing when changes feed was consumed
> ------------------------------------------------------
>
>                 Key: COUCHDB-993
>                 URL: https://issues.apache.org/jira/browse/COUCHDB-993
>             Project: CouchDB
>          Issue Type: Bug
>          Components: Replication
>    Affects Versions: 1.0.1, 1.0.2
>            Reporter: Sebastian Cohnen
>             Fix For: 1.0.2, 1.1
>
>         Attachments: couchdb-993.patch
>
>
> Yesterday I hit a bug, where pull replication is dying which is resulting in a {exit,{json_encode,{bad_term,<0.133.0>}}} error (CouchDB is trying to encode a PID into JSON).
> Adam and Paul had a look at this issue yesterday and they found the underlying issue: There was a missing clause catching the exit message when the changes feed was consumed and ibrowse closes the HTTP connection for that feed.
> Adam wrote a quick patch yesterday, which I'll append here too (applies cleanly to 1.0.x at time of writing).
> (Sorry for any inaccuracy, I only understood the issue partially)

--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira

[jira] Commented: (COUCHDB-993) Replication is crashing when changes feed was consumed

Posted by "Sebastian Cohnen (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/COUCHDB-993?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12975817#action_12975817 ] 

Sebastian Cohnen commented on COUCHDB-993:
------------------------------------------

I cannot reproduce this error locally anymore. However I still see some odd peaks in resource usage (memory/cpu). For now it looks okay, but I already said to Paul on IRC couple of days ago that I'm going to perform some more extensive testing and profiling to figure out where and - maybe with your help - why these occur. I'm not sure if these usage patterns are expected or not, but I hope that there is some more room for improvement here.

> Replication is crashing when changes feed was consumed
> ------------------------------------------------------
>
>                 Key: COUCHDB-993
>                 URL: https://issues.apache.org/jira/browse/COUCHDB-993
>             Project: CouchDB
>          Issue Type: Bug
>          Components: Replication
>    Affects Versions: 1.0.1, 1.0.2
>            Reporter: Sebastian Cohnen
>             Fix For: 1.0.2, 1.1
>
>         Attachments: couchdb-993.patch
>
>
> Yesterday I hit a bug, where pull replication is dying which is resulting in a {exit,{json_encode,{bad_term,<0.133.0>}}} error (CouchDB is trying to encode a PID into JSON).
> Adam and Paul had a look at this issue yesterday and they found the underlying issue: There was a missing clause catching the exit message when the changes feed was consumed and ibrowse closes the HTTP connection for that feed.
> Adam wrote a quick patch yesterday, which I'll append here too (applies cleanly to 1.0.x at time of writing).
> (Sorry for any inaccuracy, I only understood the issue partially)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Updated: (COUCHDB-993) Replication is crashing when changes feed was consumed

Posted by "Sebastian Cohnen (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/COUCHDB-993?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Sebastian Cohnen updated COUCHDB-993:
-------------------------------------

    Attachment: couchdb-993.patch

patch by Adam Kocolosk

> Replication is crashing when changes feed was consumed
> ------------------------------------------------------
>
>                 Key: COUCHDB-993
>                 URL: https://issues.apache.org/jira/browse/COUCHDB-993
>             Project: CouchDB
>          Issue Type: Bug
>          Components: Replication
>    Affects Versions: 1.0.1, 1.0.2
>            Reporter: Sebastian Cohnen
>         Attachments: couchdb-993.patch
>
>
> Yesterday I hit a bug, where pull replication is dying which is resulting in a {exit,{json_encode,{bad_term,<0.133.0>}}} error (CouchDB is trying to encode a PID into JSON).
> Adam and Paul had a look at this issue yesterday and they found the underlying issue: There was a missing clause catching the exit message when the changes feed was consumed and ibrowse closes the HTTP connection for that feed.
> Adam wrote a quick patch yesterday, which I'll append here too (applies cleanly to 1.0.x at time of writing).
> (Sorry for any inaccuracy, I only understood the issue partially)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (COUCHDB-993) Replication is crashing when changes feed was consumed

Posted by "Sebastian Cohnen (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/COUCHDB-993?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12973736#action_12973736 ] 

Sebastian Cohnen commented on COUCHDB-993:
------------------------------------------

Paul,

as discussed on IRC: yes, the replicator isn't dying anymore. But apparently I've hit another bug causing CouchDB to crash with OOME. This is likely not related to this reported issue and maybe just a special case for my setup.

> Replication is crashing when changes feed was consumed
> ------------------------------------------------------
>
>                 Key: COUCHDB-993
>                 URL: https://issues.apache.org/jira/browse/COUCHDB-993
>             Project: CouchDB
>          Issue Type: Bug
>          Components: Replication
>    Affects Versions: 1.0.1, 1.0.2
>            Reporter: Sebastian Cohnen
>         Attachments: couchdb-993.patch
>
>
> Yesterday I hit a bug, where pull replication is dying which is resulting in a {exit,{json_encode,{bad_term,<0.133.0>}}} error (CouchDB is trying to encode a PID into JSON).
> Adam and Paul had a look at this issue yesterday and they found the underlying issue: There was a missing clause catching the exit message when the changes feed was consumed and ibrowse closes the HTTP connection for that feed.
> Adam wrote a quick patch yesterday, which I'll append here too (applies cleanly to 1.0.x at time of writing).
> (Sorry for any inaccuracy, I only understood the issue partially)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


[jira] Commented: (COUCHDB-993) Replication is crashing when changes feed was consumed

Posted by "Paul Joseph Davis (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/COUCHDB-993?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12973729#action_12973729 ] 

Paul Joseph Davis commented on COUCHDB-993:
-------------------------------------------

Sebastian,

Does this patch fix the issue for you?

For reference, the error was triggered by the ibrowse connection closing and being mistaken for the changes loop pid. This new clause just recognizes the ibrowse pid and ignores the exit. We never tracked down why the ibrowse connection was closed though.

> Replication is crashing when changes feed was consumed
> ------------------------------------------------------
>
>                 Key: COUCHDB-993
>                 URL: https://issues.apache.org/jira/browse/COUCHDB-993
>             Project: CouchDB
>          Issue Type: Bug
>          Components: Replication
>    Affects Versions: 1.0.1, 1.0.2
>            Reporter: Sebastian Cohnen
>         Attachments: couchdb-993.patch
>
>
> Yesterday I hit a bug, where pull replication is dying which is resulting in a {exit,{json_encode,{bad_term,<0.133.0>}}} error (CouchDB is trying to encode a PID into JSON).
> Adam and Paul had a look at this issue yesterday and they found the underlying issue: There was a missing clause catching the exit message when the changes feed was consumed and ibrowse closes the HTTP connection for that feed.
> Adam wrote a quick patch yesterday, which I'll append here too (applies cleanly to 1.0.x at time of writing).
> (Sorry for any inaccuracy, I only understood the issue partially)

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.