Return-Path: Delivered-To: apmail-jakarta-lucene-dev-archive@apache.org Received: (qmail 87718 invoked from network); 19 Feb 2003 03:44:58 -0000 Received: from exchange.sun.com (192.18.33.10) by daedalus.apache.org with SMTP; 19 Feb 2003 03:44:58 -0000 Received: (qmail 27577 invoked by uid 97); 19 Feb 2003 03:46:40 -0000 Delivered-To: qmlist-jakarta-archive-lucene-dev@nagoya.betaversion.org Received: (qmail 27570 invoked from network); 19 Feb 2003 03:46:39 -0000 Received: from daedalus.apache.org (HELO apache.org) (208.185.179.12) by nagoya.betaversion.org with SMTP; 19 Feb 2003 03:46:39 -0000 Received: (qmail 87442 invoked by uid 500); 19 Feb 2003 03:44:56 -0000 Mailing-List: contact lucene-dev-help@jakarta.apache.org; run by ezmlm Precedence: bulk List-Unsubscribe: List-Subscribe: List-Help: List-Post: List-Id: "Lucene Developers List" Reply-To: "Lucene Developers List" Delivered-To: mailing list lucene-dev@jakarta.apache.org Received: (qmail 87431 invoked from network); 19 Feb 2003 03:44:55 -0000 Received: from mail2.hypermall.com (216.241.37.118) by daedalus.apache.org with SMTP; 19 Feb 2003 03:44:55 -0000 Received: from [216.241.38.72] (helo=www.doomdark.org) by mail2.hypermall.com with esmtp (Exim 3.36 #1) id 18lLAL-0008JR-00 for lucene-dev@jakarta.apache.org; Tue, 18 Feb 2003 20:45:01 -0700 Content-Type: text/plain; charset="iso-8859-1" From: Tatu Saloranta Reply-To: tatu@hypermall.net Organization: Linux-users missalie To: "Lucene Developers List" Subject: Re: FSDirectory patch for file renaming Date: Tue, 18 Feb 2003 20:54:30 -0700 User-Agent: KMail/1.4.3 References: <20030217201833.3529.qmail@web12701.mail.yahoo.com> In-Reply-To: <20030217201833.3529.qmail@web12701.mail.yahoo.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Message-Id: <200302182054.30942.tatu@hypermall.net> X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N X-Spam-Rating: daedalus.apache.org 1.6.2 0/1000/N This may be getting bit off-topic, but since I'm currently using renameTo() on a project, I was wondering what are exact conditions under which people have seen this problem (I got the impression it's much more common on certain platforms etc?). So is true that the problem mostly (only?) occurs when following conditions are met: (a) A file with name renameTo() would rename another file existed earlier (b) 'Old' file is deleted (c) renameTo() tries to rename new file to 'old' file name, and native file system for some reason still thinks that file exists? or are there other cases where same problem occurs? And also, is this more frequent on Windows platform? (I haven't seen this on Solaris or Linux, but I haven't had to use renameTo() heavily). And finally, has anyone seen same problem when renaming directories? I'm basically implementing a "real time" (ie. almost instant access to current data) background reindexing with Lucene, and need renameTo() only for directory renaming, and was wondering if I should add similar workaround to my code, even before hitting the problem (better safe than sorry). To make search available without interruptions I'm copying existing index directory to a work dir, do updates (for all changed docs remove from + add to index), remove old index and rename working dir to index. During first steps old index is still available, and during last steps I'm just temporarily sync'ing search engine object to prevent new queries from using that index (that's the main idea -- implementation is bit more complicated as it's possible some searches have already started using that index). -+ Tatu +- --------------------------------------------------------------------- To unsubscribe, e-mail: lucene-dev-unsubscribe@jakarta.apache.org For additional commands, e-mail: lucene-dev-help@jakarta.apache.org