ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Conor MacNeill <>
Subject Re: buildStarted/Finished and subbuilds
Date Wed, 23 Jun 2004 14:35:19 GMT
Stefan Bodewig wrote:
> On Wed, 23 Jun 2004, Conor MacNeill <>
> wrote:
> Unfortunately this wouldn't help.
> * RecorderEntry wants to write something to the file in buildFinished,
>   if we close the file in projectFinished, this would try to write to
>   a closed file in the main build.
> * Similar, AntClassLoaders used in the master build would be cleaned
>   as soon as the subbuild finishes since it is registered as a build
>   listener for the subbuild as well.  This would be way too early.

Well, you could still take the approach of removing the main build
listeners and then fire a SubBuildFinished on all the remaining
listeners that are BuildListener2. Pretty similar to your original
without hardcoding a specific class in there, which may let other
build listeners do useful stuff at the end of a subbuild.

I wonder if we should have separate lists for objects just to listen to
their project and not events from subbuilds. Really we have overloaded
the event interface to provide a cleanup mechanism. Probably too much
work to separate them.

Just to note that cleanup should be safe to call on the AntClassLoaders
at any time if not necessarily optimal for performance. If that is not
true, I'm not sure you can be safe cleaning them up at sub-build
finished time :-)


To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message