Return-Path: X-Original-To: apmail-couchdb-commits-archive@www.apache.org Delivered-To: apmail-couchdb-commits-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id E79B447F7 for ; Wed, 8 Jun 2011 21:30:26 +0000 (UTC) Received: (qmail 51617 invoked by uid 500); 8 Jun 2011 21:30:26 -0000 Delivered-To: apmail-couchdb-commits-archive@couchdb.apache.org Received: (qmail 51571 invoked by uid 500); 8 Jun 2011 21:30:26 -0000 Mailing-List: contact commits-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 commits@couchdb.apache.org Received: (qmail 51564 invoked by uid 99); 8 Jun 2011 21:30:26 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 08 Jun 2011 21:30:26 +0000 X-ASF-Spam-Status: No, hits=-1996.4 required=5.0 tests=ALL_TRUSTED,FS_REPLICA X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 08 Jun 2011 21:30:24 +0000 Received: by eris.apache.org (Postfix, from userid 65534) id A1ECD23889EA; Wed, 8 Jun 2011 21:30:03 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r1133561 - /couchdb/trunk/src/couchdb/couch_replicator.erl Date: Wed, 08 Jun 2011 21:30:03 -0000 To: commits@couchdb.apache.org From: randall@apache.org X-Mailer: svnmailer-1.0.8 Message-Id: <20110608213003.A1ECD23889EA@eris.apache.org> X-Virus-Checked: Checked by ClamAV on apache.org Author: randall Date: Wed Jun 8 21:30:03 2011 New Revision: 1133561 URL: http://svn.apache.org/viewvc?rev=1133561&view=rev Log: let dbs be closed implicitly when replication dies We have the supervision tree and monitoring set up with ref counter. There's really no need to call close here and it generates log noise when a user DELETEs a local DB involved in replication unless we track what happened and doing some nil-ing or special casing. Just letting it all be implicit seems easiest. Closes COUCHDB-863. Modified: couchdb/trunk/src/couchdb/couch_replicator.erl Modified: couchdb/trunk/src/couchdb/couch_replicator.erl URL: http://svn.apache.org/viewvc/couchdb/trunk/src/couchdb/couch_replicator.erl?rev=1133561&r1=1133560&r2=1133561&view=diff ============================================================================== --- couchdb/trunk/src/couchdb/couch_replicator.erl (original) +++ couchdb/trunk/src/couchdb/couch_replicator.erl Wed Jun 8 21:30:03 2011 @@ -478,9 +478,7 @@ terminate(Reason, State) -> terminate_cleanup(State) -> couch_task_status:update("Finishing"), stop_db_compaction_notifier(State#rep_state.source_db_compaction_notifier), - stop_db_compaction_notifier(State#rep_state.target_db_compaction_notifier), - couch_api_wrap:db_close(State#rep_state.source), - couch_api_wrap:db_close(State#rep_state.target). + stop_db_compaction_notifier(State#rep_state.target_db_compaction_notifier). do_last_checkpoint(#rep_state{seqs_in_progress = [],