You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
On a project that I'm working on, we need to use a patched version of a Maven Extension (specified with .mvn/extensions.xml) that is stored in an internal Maven repository. When using Maven we are able to download the Maven Extension from a pluginRepository specified in the settings.xml (we use --settings option to point to a project specific settings.xml). When using mvnd this doesn't work.
From my investigation it seams that Maven Daemon doesn't resolve the settings.xml passed with --settings option when downloading Maven Core Extensions. In fact it tries to download it from central (https://repo.maven.apache.org/maven2). In our settings.xml we use a mirror of Maven central for both dependencies and plugins. This makes me think that mvnd doesn't use the specified settings.xml at early stage when it needs to resolve Maven Core Extensions defined in .mvn/extensions.xml.
We are using mvnd version 1.0.2.
Partial stacktrace:
java.lang.RuntimeException: Could not initialize org.mvndaemon.mvnd.daemon.Server
at org.mvndaemon.mvnd.daemon.Server.<init>(Server.java:171)
at org.mvndaemon.mvnd.daemon.Server.main(Server.java:103)
at java.base/jdk.internal.reflect.DirectMethodHandleAccessor.invoke(DirectMethodHandleAccessor.java:103)
at java.base/java.lang.reflect.Method.invoke(Method.java:580)
at org.codehaus.plexus.classworlds.launcher.Launcher.launchStandard(Launcher.java:292)
at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:208)
at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:361)
at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:314)
Caused by: java.lang.reflect.InvocationTargetException
at java.base/jdk.internal.reflect.DirectConstructorHandleAccessor.newInstance(DirectConstructorHandleAccessor.java:74)
at java.base/java.lang.reflect.Constructor.newInstanceWithCaller(Constructor.java:502)
at java.base/java.lang.reflect.Constructor.newInstance(Constructor.java:486)
at org.mvndaemon.mvnd.daemon.Server.<init>(Server.java:136)
... 7 more
Caused by: org.apache.maven.cli.internal.ExtensionResolutionException: Extension <omitted> or one of its dependencies could not be resolved: Plugin <omitted> or one of its dependencies could not be resolved:
Could not find artifact <omitted> in central (https://repo.maven.apache.org/maven2)
at org.apache.maven.cli.internal.BootstrapCoreExtensionManager.resolveExtension(BootstrapCoreExtensionManager.java:182)
at org.apache.maven.cli.internal.BootstrapCoreExtensionManager.resolveCoreExtensions(BootstrapCoreExtensionManager.java:115)
at org.apache.maven.cli.internal.BootstrapCoreExtensionManager.loadCoreExtensions(BootstrapCoreExtensionManager.java:99)
at org.apache.maven.cli.DaemonMavenCli.loadCoreExtensions(DaemonMavenCli.java:765)
at org.apache.maven.cli.DaemonMavenCli.container(DaemonMavenCli.java:668)
at org.apache.maven.cli.DaemonMavenCli.<init>(DaemonMavenCli.java:205)
at java.base/jdk.internal.reflect.DirectConstructorHandleAccessor.newInstance(DirectConstructorHandleAccessor.java:62)
... 10 more
Caused by: org.apache.maven.plugin.PluginResolutionException: Plugin <omitted> or one of its dependencies could not be resolved:
Could not find artifact <omitted> in central (https://repo.maven.apache.org/maven2)
at org.apache.maven.plugin.internal.DefaultPluginDependenciesResolver.resolveInternal(DefaultPluginDependenciesResolver.java:234)
at org.apache.maven.plugin.internal.DefaultPluginDependenciesResolver.resolveCoreExtension(DefaultPluginDependenciesResolver.java:159)
at org.apache.maven.cli.internal.BootstrapCoreExtensionManager.resolveExtension(BootstrapCoreExtensionManager.java:174)
... 16 more
----- End of the daemon output -----
at org.mvndaemon.mvnd.client.DaemonConnector.startDaemon(DaemonConnector.java:330)
at org.mvndaemon.mvnd.client.DaemonConnector.connect(DaemonConnector.java:123)
at org.mvndaemon.mvnd.client.DefaultClient.execute(DefaultClient.java:353)
at org.mvndaemon.mvnd.client.DefaultClient.main(DefaultClient.java:171)
at [email protected]/java.lang.invoke.LambdaForm$DMH/sa346b79c.invokeStaticInit(LambdaForm$DMH)
The text was updated successfully, but these errors were encountered:
Is there ANY chance to try your build by current master of mvnd (build master of maven then master of mvnd)? I understand it is Maven 4, not Maven 3 as in 1.0.2, but still...
On a project that I'm working on, we need to use a patched version of a Maven Extension (specified with
.mvn/extensions.xml
) that is stored in an internal Maven repository. When using Maven we are able to download the Maven Extension from a pluginRepository specified in the settings.xml (we use --settings option to point to a project specific settings.xml). When using mvnd this doesn't work.From my investigation it seams that Maven Daemon doesn't resolve the settings.xml passed with
--settings
option when downloading Maven Core Extensions. In fact it tries to download it fromcentral (https://repo.maven.apache.org/maven2)
. In our settings.xml we use a mirror of Maven central for both dependencies and plugins. This makes me think that mvnd doesn't use the specified settings.xml at early stage when it needs to resolve Maven Core Extensions defined in.mvn/extensions.xml
.We are using mvnd version 1.0.2.
Partial stacktrace:
The text was updated successfully, but these errors were encountered: