Return-Path: Delivered-To: apmail-lucene-java-dev-archive@www.apache.org Received: (qmail 19755 invoked from network); 30 Oct 2006 23:14:03 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 30 Oct 2006 23:14:03 -0000 Received: (qmail 6957 invoked by uid 500); 30 Oct 2006 23:14:13 -0000 Delivered-To: apmail-lucene-java-dev-archive@lucene.apache.org Received: (qmail 6934 invoked by uid 500); 30 Oct 2006 23:14:13 -0000 Mailing-List: contact java-dev-help@lucene.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: java-dev@lucene.apache.org Delivered-To: mailing list java-dev@lucene.apache.org Received: (qmail 6923 invoked by uid 99); 30 Oct 2006 23:14:13 -0000 Received: from herse.apache.org (HELO herse.apache.org) (140.211.11.133) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 30 Oct 2006 15:14:13 -0800 X-ASF-Spam-Status: No, hits=-0.0 required=10.0 tests=SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (herse.apache.org: domain of DORONC@il.ibm.com designates 195.212.29.154 as permitted sender) Received: from [195.212.29.154] (HELO mtagate5.de.ibm.com) (195.212.29.154) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 30 Oct 2006 15:13:56 -0800 Received: from d12nrmr1607.megacenter.de.ibm.com (d12nrmr1607.megacenter.de.ibm.com [9.149.167.49]) by mtagate5.de.ibm.com (8.13.8/8.13.8) with ESMTP id k9UNDYSb284742 for ; Mon, 30 Oct 2006 23:13:34 GMT Received: from d12av02.megacenter.de.ibm.com (d12av02.megacenter.de.ibm.com [9.149.165.228]) by d12nrmr1607.megacenter.de.ibm.com (8.13.6/8.13.6/NCO v8.1.1) with ESMTP id k9UNGPuA2723902 for ; Tue, 31 Oct 2006 00:16:25 +0100 Received: from d12av02.megacenter.de.ibm.com (loopback [127.0.0.1]) by d12av02.megacenter.de.ibm.com (8.12.11.20060308/8.13.3) with ESMTP id k9UNDXK9020063 for ; Tue, 31 Oct 2006 00:13:33 +0100 Received: from d12mc102.megacenter.de.ibm.com (d12mc102.megacenter.de.ibm.com [9.149.167.114]) by d12av02.megacenter.de.ibm.com (8.12.11.20060308/8.12.11) with ESMTP id k9UNDXYN020060 for ; Tue, 31 Oct 2006 00:13:33 +0100 Subject: lock path thoughts To: java-dev@lucene.apache.org X-Mailer: Lotus Notes Release 7.0 HF277 June 21, 2006 Message-ID: From: Doron Cohen Date: Mon, 30 Oct 2006 15:12:58 -0800 X-MIMETrack: Serialize by Router on D12MC102/12/M/IBM(Release 7.0.1HF269 | June 22, 2006) at 31/10/2006 01:16:25 MIME-Version: 1.0 Content-type: text/plain; charset=US-ASCII X-Virus-Checked: Checked by ClamAV on apache.org (extracted from issue 665 (turned to be non related to that issue).) In NFS or other shared fs situations, Locks are maintained in a specified folder, but a lock file name is derived from the full path of the index dir, actually the canonical name of this dir. So, if the same index is accessed by two machines, the / / root of that index dir must be named the same in all the machines on which Lucene is invoked to access/maintain that index. Since File.getCanonicalPath() is system dependent, and since sometimes even for the same type of OS the mount names differ, Lucene has the setLockPrefix() API that allows users to configure locks prefix path in each machine. This seems like a source for possible problems, when users mis configure their lock prefixes. - if the index path was not configured correctly, the index would not be found, and this is likely to be found and fixed pretty soon. But if lock path prefixes are misconfigured, chances are that the index would get corrupted. This would be avoided if index locks are maintained in the index folder. I searched the lists for previous discussions on this 'design decision' - i.e. where the index locks reside - found none. Wouldn't it simplify matters to have the locks in the index dir? Any disadvantages of this? Thanks, Doron --------------------------------------------------------------------- To unsubscribe, e-mail: java-dev-unsubscribe@lucene.apache.org For additional commands, e-mail: java-dev-help@lucene.apache.org