From dev-return-10356-apmail-couchdb-dev-archive=couchdb.apache.org@couchdb.apache.org Tue Jun 22 23:38:02 2010 Return-Path: Delivered-To: apmail-couchdb-dev-archive@www.apache.org Received: (qmail 96771 invoked from network); 22 Jun 2010 23:38:01 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 22 Jun 2010 23:38:01 -0000 Received: (qmail 89829 invoked by uid 500); 22 Jun 2010 23:38:01 -0000 Delivered-To: apmail-couchdb-dev-archive@couchdb.apache.org Received: (qmail 89737 invoked by uid 500); 22 Jun 2010 23:38:00 -0000 Mailing-List: contact dev-help@couchdb.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@couchdb.apache.org Delivered-To: mailing list dev@couchdb.apache.org Received: (qmail 89728 invoked by uid 99); 22 Jun 2010 23:38:00 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 22 Jun 2010 23:38:00 +0000 X-ASF-Spam-Status: No, hits=3.6 required=10.0 tests=FREEMAIL_FROM,FS_REPLICA,RCVD_IN_DNSWL_NONE,SPF_PASS,T_TO_NO_BRKTS_FREEMAIL X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of robert.newson@gmail.com designates 74.125.82.180 as permitted sender) Received: from [74.125.82.180] (HELO mail-wy0-f180.google.com) (74.125.82.180) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 22 Jun 2010 23:37:52 +0000 Received: by wyf19 with SMTP id 19so4280476wyf.11 for ; Tue, 22 Jun 2010 16:37:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:received:date:message-id :subject:from:to:content-type; bh=wbWMva6rViN64/zHivD+L2egfu119xwL2X1Hf1p0IvQ=; b=XbJ4cP1wPpd/H5UjBcXtwO4ebvXa9y+s0DUOlHsBVLavMCAK+/shYBMc8JwLaSRHON E1aMD4o7it8i9ZW2IP8MSLScC/xLFKFNDu0WaZTCWb8Qr/ysUqjrn0SxYHZmg4Gy0Iyo PKQskfdgsZJqIIPYe6iJp1nfhE2+g4JGmDRl8= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:content-type; b=MBU8n8O4RPg/rl8u6lmwHixJUQBb1BXdXQ0F2O+NPMW0X1xE0EiAU6jndwT3+Jzkbh mkoSMQ50uqUcRjFqOWckRglpMkKSjodtKFRvIL60n+Ya/eRoGNzIg+fzAHmEk30DPafx CPF7PhYsvedyd7RntbCBLI1daURtvIOwQF+Cs= MIME-Version: 1.0 Received: by 10.216.158.205 with SMTP id q55mr1869923wek.66.1277249852425; Tue, 22 Jun 2010 16:37:32 -0700 (PDT) Received: by 10.216.51.3 with HTTP; Tue, 22 Jun 2010 16:37:32 -0700 (PDT) Date: Wed, 23 Jun 2010 00:37:32 +0100 Message-ID: Subject: make_replication_id excludes port. From: Robert Newson To: dev@couchdb.apache.org Content-Type: text/plain; charset=ISO-8859-1 X-Virus-Checked: Checked by ClamAV on apache.org All, I was testing some clustering code locally and noticed that my gossip-based state replication was always reporting; [info] [<0.361.0>] Replication records differ. Scanning histories to find a common ancestor. [info] [<0.361.0>] no common ancestry -- performing full replication I assumed it was my code (since I call couch_rep:replicate directly) but it wasn't. it turns out that make_replication_id ignores the port, which was the only thing that varied when testing a three node system on my laptop. This caused all the checkpoint documents to get overwritten, forcing full replication every time. I'm sure there's a reason ("%% funky algorithm to preserve backwards compatibility") but I wonder if this could be re-examined? It worries me that testing multiple couchdb instances locally behaves differently (actually, incorrectly) than testing multiple couchdb instances on real, separate hosts. B.