Return-Path: Delivered-To: apmail-lucene-java-dev-archive@www.apache.org Received: (qmail 38220 invoked from network); 14 Sep 2006 02:49:51 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (209.237.227.199) by minotaur.apache.org with SMTP; 14 Sep 2006 02:49:51 -0000 Received: (qmail 87221 invoked by uid 500); 14 Sep 2006 02:49:49 -0000 Delivered-To: apmail-lucene-java-dev-archive@lucene.apache.org Received: (qmail 87181 invoked by uid 500); 14 Sep 2006 02:49:49 -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 87170 invoked by uid 99); 14 Sep 2006 02:49:49 -0000 Received: from asf.osuosl.org (HELO asf.osuosl.org) (140.211.166.49) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 13 Sep 2006 19:49:49 -0700 X-ASF-Spam-Status: No, hits=0.5 required=10.0 tests=DNS_FROM_RFC_ABUSE,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (asf.osuosl.org: domain of yseeley@gmail.com designates 64.233.166.176 as permitted sender) Received: from [64.233.166.176] (HELO py-out-1112.google.com) (64.233.166.176) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 13 Sep 2006 19:49:42 -0700 Received: by py-out-1112.google.com with SMTP id w49so2825806pyg for ; Wed, 13 Sep 2006 19:49:15 -0700 (PDT) DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=gmail.com; h=received:message-id:date:from:sender:to:subject:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references:x-google-sender-auth; b=ktZbxCfyN7UkTfqQVMOHz5IRVnLyVT4BftqZrRVKjpFeD3u4jMiWTZZ4fV0qn4XjI3/fk5gsbY4/wvUWyMQVDz9YZ0FTiTwJwkCED1Q/qvmZc/HVmdkV6/uqcSiolou2ycIVtJoOWa2rq2p+lJqEfpznPASEeNUHLIjIJ2BKoKk= Received: by 10.35.84.12 with SMTP id m12mr14166813pyl; Wed, 13 Sep 2006 19:49:15 -0700 (PDT) Received: by 10.35.11.9 with HTTP; Wed, 13 Sep 2006 19:49:15 -0700 (PDT) Message-ID: Date: Wed, 13 Sep 2006 22:49:15 -0400 From: "Yonik Seeley" Sender: yseeley@gmail.com To: java-dev@lucene.apache.org Subject: Re: [jira] Commented: (LUCENE-665) temporary file access denied on Windows In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <4508722B.3010202@mikemccandless.com> <4508809C.4000204@mikemccandless.com> <4508BE24.8050600@mikemccandless.com> X-Google-Sender-Auth: deaab2ca3088498d X-Virus-Checked: Checked by ClamAV on apache.org X-Spam-Rating: minotaur.apache.org 1.6.2 0/1000/N On 9/13/06, Yonik Seeley wrote: > On 9/13/06, Michael McCandless wrote: > > Yonik Seeley wrote: > > >> But, I'm still renaming segments_N.new -> segments_N, > > > > > > Hmmm, remind me why you need the .new file? Why can't you just create > > > segments_N after you are finished writing all of the segments? > > > > Because there could be a reader that tries to read the file before it's > > done being written. It would hit EOF and throw an IOException. > > Ahh, right... unlikely (the segments file is pretty small), but possible. > > Another alternative (since this changes the index format anyway) is to > put something in the segments file to detect if it's partially > written... something like the size of the file or the number of > segments. I don't know if the extra complexity would be worth saving > the creation time of an extra file or not... Hey wait... the segments file already has the number of segments. Can't you tell if it's not yet complete? -Yonik --------------------------------------------------------------------- To unsubscribe, e-mail: java-dev-unsubscribe@lucene.apache.org For additional commands, e-mail: java-dev-help@lucene.apache.org