[JBoss JIRA] (FORGE-2218) Mojos should run in an isolated classloader
by George Gastaldi (JIRA)
George Gastaldi created FORGE-2218:
--------------------------------------
Summary: Mojos should run in an isolated classloader
Key: FORGE-2218
URL: https://issues.jboss.org/browse/FORGE-2218
Project: Forge
Issue Type: Enhancement
Components: Build Tools - Maven, Furnace (Container)
Affects Versions: 2.14.0.Final
Reporter: George Gastaldi
Fix For: 2.x Future
The AddonInstallMojo runs in the same classloader as Maven. The problem lies when the Maven version used to run the plugin uses a different API version than Furnace, for example Aether 0.9.0 and Aether 1.0.
Since Classworlds (the mechanism using in Maven to "isolate" classes in mojos) does not load Aether classes, the code should be compatible with the running Maven version, otherwise class structure errors will be thrown and the execution will fail.
One solution is to start Furnace, deploy the addon-manager addon and lookup services instead of instantiating {{AddonManagerImpl}}.
--
This message was sent by Atlassian JIRA
(v6.3.11#6341)