Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [m2e-users] Having a Bad Week - eclipse sick

Thanks, Benson, for a very cogent explanation.

Seems there is another hood I have to crawl under just to survive, a situation that I can't help but think shouldn't be happening but is.

As you say, Mothra vs. Godzilla, and we mere mortals are but collateral damage.

Steve

On 03/27/2011 07:42 AM, Benson Margulies wrote:
I am no substitute for a short course on the garbage collector, but here goes.

For reasons I won't pretend to be able to explain clearly and
concisely, the JVM treats the binary representation of classes (that
is to say, your code), and some ancillary data differently than it
treats ordinary objects that you allocate with 'new'. The space
available for this data is called the 'permanent generation', or
PermGen. it's a bit of a misnomer, since it can. in some
circumstances, be reused.

The important thing about PermGen space is that is is under separate
control from the ordinary heap. It doesn't matter what you set the
heap size to with -Xmx. -XX:MaxPermSize=xxxxx control the maximum.

Eclipse is very thirsty for permgen space because it uses OSGi. OSGi's
mission in life is to keep independent components independent. It does
this by creating many classloaders, and, in many cases, loading
exactly the very same class into many of them. Thus Eclipse, even
before you plugin in M2E, loads more classes, and so needs more
PermGen space, then an 'average' Java application.

Now throw Maven into the mixture. Here we have another device that
creates many class loaders so as to allow component isolation. More
PermGen space usage.

You are correct that my eclipse.ini is MacOS specific. All
eclipse.ini's are platform-specific. There are a number of resources
on the web (including a stackoverflow question or 10) that discuss
tuning eclipse.ini. I recommend that you find one, and see how to add
-XX:MaxPermGen and -XXPermGen to yours with generous numbers, and see
what you see.

YYMV, of course. XP is very long in the tooth, and you may be having
problems related to Mothra versus Godzilla (e.g. Microsoft versus
Snoracle) that have nothing to do with what I've written above.
_______________________________________________
m2e-users mailing list
m2e-users@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/m2e-users





Back to the top