I've made both these changes - thanks Benjamin!
- Brett
On 17/03/2009, at 9:20 PM, Brett Porter wrote:
On 17/03/2009, at 9:10 PM, Benjamin Bentmann wrote:
For the sake of reduced heap consumption, how about unregistering
the validator right after createChildContainer() returns such that
the validator can be garbage collected?
Imagine a plugin A which depends on another plugin artifact B, like
people would do when extending mojos (see also MNG-3217). When
ensurePluginContainerIsComplete() is called, the plugin descriptor
from artifact B will be discovered and will cause the validator to
create error strings. Furtheremore, those error strings will be
created n times, where n is the total number of plugin
dependencies, each triggering an invocation of
MavenPluginValidator.componentDiscovered().
AH! Thanks, I'd planned to test that and it slipped my mind when I
finished. I can fix this up.
Having said this, we might as well consider unregistering the
plugin collector from the plugin container in a future Maven
version. We're only interested in the descriptor from the plugin
main artifact so spontaneously I don't see a reason to still have
the collector around when the plugin container is populated with
the plugin dependencies.
I agree - I'll do this separately though in case it affects that use
case you mentioned above.
Thanks!
Brett
--
Brett Porter
[email protected]
http://blogs.exist.com/bporter/
--
Brett Porter
[email protected]
http://blogs.exist.com/bporter/
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]