Return-Path: Delivered-To: apmail-lucene-java-dev-archive@www.apache.org Received: (qmail 35646 invoked from network); 17 Mar 2010 18:16:23 -0000 Received: from unknown (HELO mail.apache.org) (140.211.11.3) by 140.211.11.9 with SMTP; 17 Mar 2010 18:16:23 -0000 Received: (qmail 67715 invoked by uid 500); 17 Mar 2010 18:16:23 -0000 Delivered-To: apmail-lucene-java-dev-archive@lucene.apache.org Received: (qmail 67668 invoked by uid 500); 17 Mar 2010 18:16:23 -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 67660 invoked by uid 99); 17 Mar 2010 18:16:23 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 17 Mar 2010 18:16:23 +0000 X-ASF-Spam-Status: No, hits=-1.4 required=10.0 tests=AWL,FREEMAIL_FROM,RCVD_IN_DNSWL_NONE,SPF_PASS,T_TO_NO_BRKTS_FREEMAIL X-Spam-Check-By: apache.org Received-SPF: pass (athena.apache.org: domain of gkaczor@gmx.de designates 213.165.64.20 as permitted sender) Received: from [213.165.64.20] (HELO mail.gmx.net) (213.165.64.20) by apache.org (qpsmtpd/0.29) with SMTP; Wed, 17 Mar 2010 18:16:15 +0000 Received: (qmail 9039 invoked by uid 0); 17 Mar 2010 18:15:50 -0000 Received: from 80.187.101.179 by www133.gmx.net with HTTP; Wed, 17 Mar 2010 19:15:47 +0100 (CET) Content-Type: text/plain; charset="us-ascii" Date: Wed, 17 Mar 2010 19:15:47 +0100 From: "Gregor Kaczor" Message-ID: <20100317181547.90050@gmx.net> MIME-Version: 1.0 Subject: IndexWriter.synced field accumulates data To: java-dev@lucene.apache.org X-Authenticated: #1930454 X-Flags: 0001 X-Mailer: WWW-Mail 6100 (Global Message Exchange) X-Priority: 3 X-Provags-ID: V01U2FsdGVkX19BAcpWjiJBxWlvVRvWIQkgjVmDT9Yr8vzA6X/Frp c+HxkbQ/EsZxQeKZ4SL9Bj2lIuYeM/R74caQ== Content-Transfer-Encoding: 7bit X-GMX-UID: ay6Sf0dqX1V6F+IZcWFyu3d/SDc4NAxL X-FuHaFi: 0.62 I am running into a strange OutOfMemoryError. My small test application does index and delete some few files. This is repeated for 60k times. Optimization is run from every 2k times a file is indexed. Index size is 50KB. I did analyze the HeapDumpFile and realized that IndexWriter.synced field occupied more than half of the heap. That field is a private HashSet without a getter. Its task is to hold files which have been synced already. There are two calls to addAll and one call to add on synced but no remove or clear throughout the lifecycle of the IndexWriter instance. According to the Eclipse Memory Analyzer synced contains 32618 entries which look like file names "_e065_1.del" or "_e067.cfs" The index directory contains 10 files only. I guess synced is holding obsolete data --------------------------------------------------------------------- To unsubscribe, e-mail: java-dev-unsubscribe@lucene.apache.org For additional commands, e-mail: java-dev-help@lucene.apache.org