You are viewing a plain text version of this content. The canonical link for it is here.
Posted to m2-dev@maven.apache.org by Brett Porter <br...@apache.org> on 2005/03/17 08:55:34 UTC

memory leak

Hi,

I've taken a look at m2 and gotten rid of the only memory leak that is
of our own doing.

Compilation and tests tend to leak during the reactor. If anyone knows
of a way to forceably dispose of a classloader and everything allocated
under it - that'd be great.
I'm guessing we can fix test leaks (though its something an individual
project needs to worry about), but compilation leaks will require either
forking, or using eclipse or something which behveas better than javac.

We should add the ability to optionally fork on everything, or once for
all tests and once for compilation to safeguard against leaks. This can
be an option for people suffering it in a long running process or
massive reactor (eg continuum). Another option for continuum is to fork
m2 instances that can act as servers for build requests. This was
something Hiram suggested.

Anyway, I think we're ok for now. The majority of plexus builds on my
machine using 18M of memory in a minute and a half (including some
rather slow tests).

- Brett



Réf. : memory leak

Posted by ju...@bnpparibas.com.

> Compilation and tests tend to leak during the reactor. If anyone knows
> of a way to forceably dispose of a classloader and everything allocated
> under it - that'd be great.

maybe this could help, just read it yesterday and seem related
http://blog.taragana.com/index.php/archive/how-to-unload-java-class/

Julien




This message and any attachments (the "message") is
intended solely for the addressees and is confidential. 
If you receive this message in error, please delete it and 
immediately notify the sender. Any use not in accord with 
its purpose, any dissemination or disclosure, either whole 
or partial, is prohibited except formal approval. The internet
can not guarantee the integrity of this message. 
BNP PARIBAS (and its subsidiaries) shall (will) not 
therefore be liable for the message if modified. 

                ---------------------------------------------

Ce message et toutes les pieces jointes (ci-apres le 
"message") sont etablis a l'intention exclusive de ses 
destinataires et sont confidentiels. Si vous recevez ce 
message par erreur, merci de le detruire et d'en avertir 
immediatement l'expediteur. Toute utilisation de ce 
message non conforme a sa destination, toute diffusion 
ou toute publication, totale ou partielle, est interdite, sauf 
autorisation expresse. L'internet ne permettant pas 
d'assurer l'integrite de ce message, BNP PARIBAS (et ses
filiales) decline(nt) toute responsabilite au titre de ce 
message, dans l'hypothese ou il aurait ete modifie.