Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Eclipse Platform » "Too many open files" problem
"Too many open files" problem [message #333307] Wed, 03 December 2008 19:55 Go to next message
Eclipse UserFriend
Originally posted by: Bill.Joy.codegear.com

I run into every once in a while since moving from Eclipse 3.3 to 3.4.1.

Eclipse can get into a mode where the UI hangs for a long time. Sometimes
afterwards the Error Log is filled with error messages about "Invalid ZIP
archive" resulting from JavaModelManager.getZipFile() getting the
ZipException "Too many open files". (Note that I can see 6 more of the
exact same message for each archive that is supposedly "invalid" -- these
are coming from different threads all doing the same time at pretty much the
same time.)

For instance, today I used the "Import Existing Projects into Workspace"
wizard and imported one plugin project. My workspace already had over 30
related plugin projects in the workspace. I also had several files open (I
think that is probably a key point). Build automatically was also enabled.

There was a really long wait with the progress dialog up (I invoked an
action which was blocked until the rebuild was complete). I took a thread
dump in the console window (I started Eclipse with eclipsec.exe) and saw
many instances of the thread
"org.eclipse.jdt.internal.ui.text.JavaReconciler". My guess is that there
was one of these per file that I had open. All these threads were doing zip
operations called by the method JarPackageFragmentRoot.computeChildren().

Suddenly there was exception after exception about "too many open files".

I think part of the problem is related to JavaModelManager which appears to
now cache zip file handles on a thread basis. Having multiple reconciler
threads running at the same time would logically seem to end up in using all
the available handles on Windows depending on how many of them were present.

There are also some major performance implications here that I don't
understand.

Guessing from the Error Log entries, there is probably some synchronization
between the threads happening since the threads are complaining about the
same archive in consecutive entries. Perhaps that is part of the
performance problem.
Re: "Too many open files" problem [message #333327 is a reply to message #333307] Thu, 04 December 2008 08:17 Go to previous message
Dani Megert is currently offline Dani MegertFriend
Messages: 3802
Registered: July 2009
Senior Member
Bill Joy wrote:
> I run into every once in a while since moving from Eclipse 3.3 to 3.4.1.
>
Thanks for the long description but the newsgroup is the wrong forum to
report bugs. Please file a bug report against JDT Core:
https://bugs.eclipse.org/bugs/enter_bug.cgi?assigned_to=jdt- core-inbox%40eclipse.org&blocked=&bug_file_loc=http% 3A%2F%2F&bug_severity=normal&bug_status=NEW&comm ent=&component=Core&contenttypeentry=&contenttyp emethod=autodetect&contenttypeselection=text%2Fplain& ;data=&dependson=&description=&flag_type-1=X& ;flag_type-2=X&flag_type-4=X&flag_type-6=X&flag_ type-7=X&flag_type-8=X&form_name=enter_bug&keywo rds=&maketemplate=Remember%20values%20as%20bookmarkable% 20template&op_sys=All&priority=P3&product=JDT&am p;qa_contact=&rep_platform=All&short_desc=&versi on=3.4.1

Dani
> Eclipse can get into a mode where the UI hangs for a long time. Sometimes
> afterwards the Error Log is filled with error messages about "Invalid ZIP
> archive" resulting from JavaModelManager.getZipFile() getting the
> ZipException "Too many open files". (Note that I can see 6 more of the
> exact same message for each archive that is supposedly "invalid" -- these
> are coming from different threads all doing the same time at pretty much the
> same time.)
>
> For instance, today I used the "Import Existing Projects into Workspace"
> wizard and imported one plugin project. My workspace already had over 30
> related plugin projects in the workspace. I also had several files open (I
> think that is probably a key point). Build automatically was also enabled.
>
> There was a really long wait with the progress dialog up (I invoked an
> action which was blocked until the rebuild was complete). I took a thread
> dump in the console window (I started Eclipse with eclipsec.exe) and saw
> many instances of the thread
> "org.eclipse.jdt.internal.ui.text.JavaReconciler". My guess is that there
> was one of these per file that I had open. All these threads were doing zip
> operations called by the method JarPackageFragmentRoot.computeChildren().
>
> Suddenly there was exception after exception about "too many open files".
>
> I think part of the problem is related to JavaModelManager which appears to
> now cache zip file handles on a thread basis. Having multiple reconciler
> threads running at the same time would logically seem to end up in using all
> the available handles on Windows depending on how many of them were present.
>
> There are also some major performance implications here that I don't
> understand.
>
> Guessing from the Error Log entries, there is probably some synchronization
> between the threads happening since the threads are complaining about the
> same archive in consecutive entries. Perhaps that is part of the
> performance problem.
>
>
>
>
Previous Topic:"Alt + Key" not working on Solaris
Next Topic:Disabling a menu that uses dynamic clause
Goto Forum:
  


Current Time: Thu Nov 07 05:12:40 GMT 2024

Powered by FUDForum. Page generated in 0.03479 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top