gnodet commented on a change in pull request #607:
URL: https://github.com/apache/maven/pull/607#discussion_r751422112



##########
File path: 
maven-core/src/main/java/org/apache/maven/plugin/internal/DefaultMavenPluginManager.java
##########
@@ -492,6 +492,21 @@ private void discoverPluginComponents( final ClassRealm 
pluginRealm, Plugin plug
 
         ClassRealm pluginRealm = pluginDescriptor.getClassRealm();
 
+        if ( pluginRealm == null )
+        {
+            try
+            {
+                setupPluginRealm( pluginDescriptor, session, null, null, null 
);
+            }
+            catch ( PluginResolutionException e )
+            {
+                String msg = "Cannot setup plugin realm [mojoDescriptor=" + 
mojoDescriptor.getId()
+                        + ", pluginDescriptor=" + pluginDescriptor.getId() + 
"]";
+                throw new PluginConfigurationException( pluginDescriptor, msg, 
e );
+            }
+            pluginRealm = pluginDescriptor.getClassRealm();
+        }
+
         if ( logger.isDebugEnabled() )

Review comment:
       @maximilian-novikov-db any idea why this snippet came through ? Is that 
actually a needed change in `maven-core` ?




-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscr...@maven.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


Reply via email to