[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [tycho-user] "Nested Equinox instance is not supported" in a custom mojo
- From: Igor Fedorenko <igor@xxxxxxxxxxxxxx>
- Date: Fri, 05 Oct 2012 09:04:39 -0400
- Delivered-to: firstname.lastname@example.org
- User-agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.6; rv:15.0) Gecko/20120907 Thunderbird/15.0.1
Maven does not have proper support for sharing classloaders among
different plugins. Most likely Maven decided it needed separate tycho
extensions plugin instance, but I can't tell why without debugging your
On 12-10-05 8:02 AM, Mickael Istria wrote:
On 10/05/2012 12:50 PM, Igor Fedorenko wrote:
You should be able to consume Equinox and Tycho services from thirdparty
mojos, just don't try to force multiple instances of singleton
components. For Equinox this means you need to contribute additional
bundles to the same framework instance used by tycho, not start new one.
IIRC, Equinox and P2 use system properties quite heavily, so all users
must share the same framework instance to work properly.
Thanks, I understand better the error, but cannot find its root cause.
I injected equinox with
/** @component */
protected EquinoxServiceFactory equinox;
I see it's done the same way in other Mojos.
But I also noticed that the plugin works when it is the only plugin
using an equinox in the reactor. If it's alone, it works; if it's in
executed in a reactor which also executes TPValidationMojo (which also
requires an equinox @component) it fails with the error described.
So it seems that both Mojo don't receive the same equinox, leading to
the error. Do you know any reason why it happens like that? Do you have
any hint for troubleshooting/debugging ?
Eclipse developer at JBoss, by Red Hat <http://www.jboss.org/tools>
My blog <http://mickaelistria.wordpress.com> - My Tweets
tycho-user mailing list