mirror of https://github.com/apache/maven.git
Set the proper default lookup realm for mojo execution - they may lookup components when executing too
git-svn-id: https://svn.apache.org/repos/asf/maven/components/trunk@497307 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
8e7dc9ef14
commit
c783818ab2
|
@ -513,7 +513,6 @@ public class DefaultPluginManager
|
|||
ClassLoader oldClassLoader = Thread.currentThread().getContextClassLoader();
|
||||
|
||||
ClassRealm pluginRealm = pluginDescriptor.getClassRealm();
|
||||
;
|
||||
|
||||
try
|
||||
{
|
||||
|
@ -521,8 +520,12 @@ public class DefaultPluginManager
|
|||
|
||||
Thread.currentThread().setContextClassLoader( pluginRealm );
|
||||
|
||||
ClassRealm oldRealm = DefaultPlexusContainer.setLookupRealm( pluginRealm );
|
||||
|
||||
plugin.execute();
|
||||
|
||||
DefaultPlexusContainer.setLookupRealm( oldRealm );
|
||||
|
||||
dispatcher.dispatchEnd( event, goalExecId );
|
||||
}
|
||||
catch ( MojoExecutionException e )
|
||||
|
|
Loading…
Reference in New Issue