Return-Path: Delivered-To: apmail-lucene-dev-archive@www.apache.org Received: (qmail 21510 invoked from network); 6 Dec 2010 13:41:33 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 6 Dec 2010 13:41:33 -0000 Received: (qmail 67716 invoked by uid 500); 6 Dec 2010 13:41:32 -0000 Delivered-To: apmail-lucene-dev-archive@lucene.apache.org Received: (qmail 67433 invoked by uid 500); 6 Dec 2010 13:41:32 -0000 Mailing-List: contact dev-help@lucene.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@lucene.apache.org Delivered-To: mailing list dev@lucene.apache.org Received: (qmail 67421 invoked by uid 99); 6 Dec 2010 13:41:31 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 06 Dec 2010 13:41:31 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.22] (HELO thor.apache.org) (140.211.11.22) by apache.org (qpsmtpd/0.29) with ESMTP; Mon, 06 Dec 2010 13:41:31 +0000 Received: from thor (localhost [127.0.0.1]) by thor.apache.org (8.13.8+Sun/8.13.8) with ESMTP id oB6DfAwi028037 for ; Mon, 6 Dec 2010 13:41:11 GMT Message-ID: <14604998.127861291642870786.JavaMail.jira@thor> Date: Mon, 6 Dec 2010 08:41:10 -0500 (EST) From: "Simon Willnauer (JIRA)" To: dev@lucene.apache.org Subject: [jira] Created: (LUCENE-2802) DirectoryReader ignores NRT SegmentInfos in #isOptimized() MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 DirectoryReader ignores NRT SegmentInfos in #isOptimized() ---------------------------------------------------------- Key: LUCENE-2802 URL: https://issues.apache.org/jira/browse/LUCENE-2802 Project: Lucene - Java Issue Type: Bug Components: Search Affects Versions: 4.0 Reporter: Simon Willnauer DirectoryReader only takes shared (with IW) SegmentInfos into account in DirectoryReader#isOptimized(). This can return true even if the actual realtime reader sees more than one segments. {code} public boolean isOptimized() { ensureOpen(); // if segmentsInfos changes in IW this can return false positive return segmentInfos.size() == 1 && !hasDeletions(); } {code} DirectoryReader should check if this reader has a non-nul segmentInfosStart and use that instead -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online. --------------------------------------------------------------------- To unsubscribe, e-mail: dev-unsubscribe@lucene.apache.org For additional commands, e-mail: dev-help@lucene.apache.org