You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@couchdb.apache.org by rnewson <gi...@git.apache.org> on 2015/10/07 15:50:16 UTC

[GitHub] couchdb-couch-replicator pull request: Duplicate jobs transition d...

GitHub user rnewson opened a pull request:

    https://github.com/apache/couchdb-couch-replicator/pull/20

    Duplicate jobs transition directly to completed state

    _replicate is idempotent but _replicator is not, one can create any
    number of documents with the same content. The burden of retrying all
    the duplicates can be excessive.
    
    A detected duplicate will now transition immediately to completed, as
    we know there's a currently running job for the exact same task.
    
    COUCHDB-2842

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/cloudant/couchdb-couch-replicator 2842-complete-duplicates

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/couchdb-couch-replicator/pull/20.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #20
    
----
commit 07345de8514da1bbdaaff1fc8168516d3a0dcd31
Author: Robert Newson <rn...@apache.org>
Date:   2015-01-17T13:04:19Z

    Duplicate jobs transition directly to completed state
    
    _replicate is idempotent but _replicator is not, one can create any
    number of documents with the same content. The burden of retrying all
    the duplicates can be excessive.
    
    A detected duplicate will now transition immediately to completed, as
    we know there's a currently running job for the exact same task.
    
    COUCHDB-2842

----


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] couchdb-couch-replicator pull request: Duplicate jobs transition d...

Posted by rnewson <gi...@git.apache.org>.
Github user rnewson commented on the pull request:

    https://github.com/apache/couchdb-couch-replicator/pull/20#issuecomment-146208236
  
    hm, no strong feeling either way except that it complicates things a bit more.
    
    We need a new replicator anyway, and we should address the state transition diagram. I want to see some classes of "error" state become terminal (not retried), so I'd defer to that time. "error" because "duplicate" should be terminal.
    
    I'm using "completed" because it's the only terminal state right now.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] couchdb-couch-replicator pull request: Duplicate jobs transition d...

Posted by kxepal <gi...@git.apache.org>.
Github user kxepal commented on the pull request:

    https://github.com/apache/couchdb-couch-replicator/pull/20#issuecomment-146243356
  
    Oh, that's a pity ):


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] couchdb-couch-replicator pull request: Duplicate jobs transition d...

Posted by rnewson <gi...@git.apache.org>.
Github user rnewson commented on the pull request:

    https://github.com/apache/couchdb-couch-replicator/pull/20#issuecomment-146204643
  
    yes, good idea.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] couchdb-couch-replicator pull request: Duplicate jobs transition d...

Posted by rnewson <gi...@git.apache.org>.
Github user rnewson commented on the pull request:

    https://github.com/apache/couchdb-couch-replicator/pull/20#issuecomment-146242520
  
    This doesn't work if the docs land in different shards, which is more likely than not.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] couchdb-couch-replicator pull request: Duplicate jobs transition d...

Posted by kxepal <gi...@git.apache.org>.
Github user kxepal commented on the pull request:

    https://github.com/apache/couchdb-couch-replicator/pull/20#issuecomment-146205191
  
    What do you think about to introduce "duplicate" state as synonym to "completed" and the reason for it will be other doc id? 


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] couchdb-couch-replicator pull request: Duplicate jobs transition d...

Posted by kxepal <gi...@git.apache.org>.
Github user kxepal commented on the pull request:

    https://github.com/apache/couchdb-couch-replicator/pull/20#issuecomment-146202906
  
    +1


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] couchdb-couch-replicator pull request: Duplicate jobs transition d...

Posted by kxepal <gi...@git.apache.org>.
Github user kxepal commented on the pull request:

    https://github.com/apache/couchdb-couch-replicator/pull/20#issuecomment-146203111
  
    On second though, could we provide some field with the reference onto duplicated by document? Should be helpful.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] couchdb-couch-replicator pull request: Duplicate jobs transition d...

Posted by rnewson <gi...@git.apache.org>.
Github user rnewson closed the pull request at:

    https://github.com/apache/couchdb-couch-replicator/pull/20


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] couchdb-couch-replicator pull request: Duplicate jobs transition d...

Posted by rnewson <gi...@git.apache.org>.
Github user rnewson commented on the pull request:

    https://github.com/apache/couchdb-couch-replicator/pull/20#issuecomment-146244322
  
    Indeed. It's regrettable that we didn't force the _id to be the replication_id, which would have prevented duplications.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---

[GitHub] couchdb-couch-replicator pull request: Duplicate jobs transition d...

Posted by rnewson <gi...@git.apache.org>.
Github user rnewson commented on the pull request:

    https://github.com/apache/couchdb-couch-replicator/pull/20#issuecomment-146242930
  
    well, not shards, it's if it's "owned" by a different node. the duplication is only detected within the node.


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastructure@apache.org or file a JIRA ticket
with INFRA.
---