Return-Path: X-Original-To: apmail-lucene-java-user-archive@www.apache.org Delivered-To: apmail-lucene-java-user-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id CA7EB115D6 for ; Mon, 24 Mar 2014 16:34:09 +0000 (UTC) Received: (qmail 85702 invoked by uid 500); 24 Mar 2014 16:32:43 -0000 Delivered-To: apmail-lucene-java-user-archive@lucene.apache.org Received: (qmail 85303 invoked by uid 500); 24 Mar 2014 16:32:29 -0000 Mailing-List: contact java-user-help@lucene.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: java-user@lucene.apache.org Delivered-To: mailing list java-user@lucene.apache.org Received: (qmail 84983 invoked by uid 99); 24 Mar 2014 16:32:13 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 24 Mar 2014 16:32:13 +0000 X-ASF-Spam-Status: No, hits=-0.7 required=5.0 tests=RCVD_IN_DNSWL_LOW,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: domain of ro.franchini@gmail.com designates 209.85.216.53 as permitted sender) Received: from [209.85.216.53] (HELO mail-qa0-f53.google.com) (209.85.216.53) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 24 Mar 2014 16:32:08 +0000 Received: by mail-qa0-f53.google.com with SMTP id w8so5508667qac.40 for ; Mon, 24 Mar 2014 09:31:46 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20120113; h=mime-version:sender:in-reply-to:references:from:date:message-id :subject:to:content-type; bh=kf9UC53QJ0ulfXZbh3Uf8qvD44AubhdXlRYIOQRXr2s=; b=Io5/HVi14fPcta+LIhwUulIp79ThQxS1mroEkGB00Q6sSkz31F7qS5SxVqHZdRgERX IKlwgCrZoZcgaGxoG9G0ee1LXWm2t0GSgl62IIjBm4C1j803sOLT46bOPyrlp5jTF20x s9yjDFQzc/y+NVlZWH06HqQ2wJpn0m8d8qYbO8+dfyTSscDHDBQTwP/Tz4D+ZkHTOiZk 41zX6SlVTOoKK+SuGPtFs2J0k8G5nAphMOEwtgqS9K9gkvcU+sYRGQiQ1QIv4VndQPMD QeNg1Df82zVTjmeflvHb2x20mKaG8o1bGEWaMF8yVDz/Tr99G3CCfCDv7QNEVuI1l/Fs oN3Q== X-Received: by 10.140.86.36 with SMTP id o33mr66308950qgd.67.1395678706712; Mon, 24 Mar 2014 09:31:46 -0700 (PDT) MIME-Version: 1.0 Sender: ro.franchini@gmail.com Received: by 10.224.16.203 with HTTP; Mon, 24 Mar 2014 09:31:25 -0700 (PDT) In-Reply-To: References: From: Roberto Franchini Date: Mon, 24 Mar 2014 17:31:25 +0100 X-Google-Sender-Auth: tfpeir2MZJGAQvMpJoKbchRxA9A Message-ID: Subject: Re: Replicator: how to use it? To: java-user@lucene.apache.org Content-Type: text/plain; charset=ISO-8859-1 X-Virus-Checked: Checked by ClamAV on apache.org On Thu, Mar 20, 2014 at 8:47 AM, Shai Erera wrote: >> >> Even if the commit is called just before the close, the close triggers >> a last commit. >> > > That seems wrong. If you do writer.commit() and them immediately > writer.close(), and there are no changes to the writer in between (i.e. a > thread comes in and adds/updates/deletes a document), then close() should > not create a new commit point. Do you see that it does? Hi, I've added a waitForMerges call before the last commit, then I close the writer: writer.waitForMerges(); writer.commit(); replicator. replicate(new IndexRevision(writer)); writer.close(); Now it works. Thank you very much for the support. RF -- Roberto Franchini The impossible is inevitable. http://www.celi.it http://www.blogmeter.it http://github.com/celi-uim http://github.com/robfrank Tel +39.011.562.71.15 jabber:ro.franchini@gmail.com skype:ro.franchini tw:@robfrankie --------------------------------------------------------------------- To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org For additional commands, e-mail: java-user-help@lucene.apache.org