maven-mvnd
maven-mvnd copied to clipboard
Failed to install artifact xxx
ENV:
Apache Maven Daemon (mvnd) 1.0-m6 windows-amd64 native client (47d4c6b9c399079d91312bb8ae35d1d76e7fd97a)
Terminal: org.jline.terminal.impl.jansi.win.JansiWinSysTerminal
Apache Maven 4.0.0-alpha-5 (26d10a4bf9a2df75feef60da01d8706f2bf77a47)
Maven home: C:\mvnd\mvn
Java version: 17.0.4, vendor: Oracle Corporation, runtime: C:\Program Files\Java\jdk-17.0.4
Default locale: zh_CN, platform encoding: GBK
OS name: "windows 11", version: "10.0", arch: "amd64", family: "windows"
cmd: mvn clean package -Ppre -DskipTests execution succeed
mvnd clean package -Ppre -DskipTests execution succeed
mvn clean install -Ppre -DskipTests execution succeed
mvnd clean install -Ppre -DskipTests execution failed
error info :
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal [32morg.apache.maven.plugins:maven-install-plugin:2.5.2:install[m [1m(default-install)[m on project [36mcommon-util[m: [1;31mFailed to install artifact com.xxx:common-util:jar:1.0-SNAPSHOT: D:\maven_repository\com\xxx\common-util\1.0-SNAPSHOT\common-util-1.0-SNAPSHOT.jar.5405012231798465179.tmp -> D:\maven_repository\com\xxx\common-util\1.0-SNAPSHOT\common-util-1.0-SNAPSHOT.jar[m
at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute2(MojoExecutor.java:341)
at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute(MojoExecutor.java:324)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:212)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:174)
at org.apache.maven.lifecycle.internal.MojoExecutor.access$000(MojoExecutor.java:77)
at org.apache.maven.lifecycle.internal.MojoExecutor$1.run(MojoExecutor.java:162)
at org.apache.maven.plugin.DefaultMojosExecutionStrategy.execute(DefaultMojosExecutionStrategy.java:39)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:159)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:114)
at io.takari.maven.builder.smart.SmartBuilderImpl.buildProject(SmartBuilderImpl.java:204)
at io.takari.maven.builder.smart.SmartBuilderImpl$ProjectBuildTask.run(SmartBuilderImpl.java:78)
at java.base/java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:539)
at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1136)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:635)
at java.base/java.lang.Thread.run(Thread.java:833)
Caused by: org.apache.maven.plugin.MojoExecutionException: Failed to install artifact com.xxx:common-util:jar:1.0-SNAPSHOT: D:\maven_repository\com\xxx\common-util\1.0-SNAPSHOT\common-util-1.0-SNAPSHOT.jar.5405012231798465179.tmp -> D:\maven_repository\com\xxx\common-util\1.0-SNAPSHOT\common-util-1.0-SNAPSHOT.jar
at org.apache.maven.plugin.install.InstallMojo.installProject(InstallMojo.java:236)
at org.apache.maven.plugin.install.InstallMojo.execute(InstallMojo.java:126)
at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:143)
at org.apache.maven.lifecycle.internal.MojoExecutor.doExecute2(MojoExecutor.java:336)
... 15 common frames omitted
Caused by: org.apache.maven.artifact.installer.ArtifactInstallationException: Failed to install artifact com.xxx:common-util:jar:1.0-SNAPSHOT: D:\maven_repository\com\xxx\common-util\1.0-SNAPSHOT\common-util-1.0-SNAPSHOT.jar.5405012231798465179.tmp -> D:\maven_repository\com\xxx\common-util\1.0-SNAPSHOT\common-util-1.0-SNAPSHOT.jar
at org.apache.maven.artifact.installer.DefaultArtifactInstaller.install(DefaultArtifactInstaller.java:96)
at org.apache.maven.plugin.install.InstallMojo.installProject(InstallMojo.java:197)
... 18 common frames omitted
Caused by: org.eclipse.aether.installation.InstallationException: Failed to install artifact com.xxx:common-util:jar:1.0-SNAPSHOT: D:\maven_repository\com\xxx\common-util\1.0-SNAPSHOT\common-util-1.0-SNAPSHOT.jar.5405012231798465179.tmp -> D:\maven_repository\com\xxx\common-util\1.0-SNAPSHOT\common-util-1.0-SNAPSHOT.jar
at org.eclipse.aether.internal.impl.DefaultInstaller.install(DefaultInstaller.java:273)
at org.eclipse.aether.internal.impl.DefaultInstaller.install(DefaultInstaller.java:220)
at org.eclipse.aether.internal.impl.DefaultInstaller.install(DefaultInstaller.java:170)
at org.eclipse.aether.internal.impl.DefaultInstaller.install(DefaultInstaller.java:135)
at org.apache.maven.internal.aether.MavenInstaller.install(MavenInstaller.java:56)
at org.eclipse.aether.internal.impl.DefaultRepositorySystem.install(DefaultRepositorySystem.java:384)
at org.apache.maven.artifact.installer.DefaultArtifactInstaller.install(DefaultArtifactInstaller.java:94)
... 19 common frames omitted
Caused by: java.nio.file.AccessDeniedException: D:\maven_repository\com\xxx\common-util\1.0-SNAPSHOT\common-util-1.0-SNAPSHOT.jar.5405012231798465179.tmp -> D:\maven_repository\com\xxx\common-util\1.0-SNAPSHOT\common-util-1.0-SNAPSHOT.jar
at java.base/sun.nio.fs.WindowsException.translateToIOException(WindowsException.java:89)
at java.base/sun.nio.fs.WindowsException.rethrowAsIOException(WindowsException.java:103)
at java.base/sun.nio.fs.WindowsFileCopy.move(WindowsFileCopy.java:317)
at java.base/sun.nio.fs.WindowsFileSystemProvider.move(WindowsFileSystemProvider.java:293)
at java.base/java.nio.file.Files.move(Files.java:1432)
at org.eclipse.aether.util.FileUtils$2.move(FileUtils.java:108)
at org.eclipse.aether.internal.impl.DefaultFileProcessor.copy(DefaultFileProcessor.java:96)
at org.eclipse.aether.internal.impl.DefaultFileProcessor.copy(DefaultFileProcessor.java:88)
at org.eclipse.aether.internal.impl.DefaultInstaller.install(DefaultInstaller.java:266)
... 25 common frames omitted'}
- verify that the build succeeds with latest Maven 3.9.x and/or 4.0-alpha-x and provide the log output
- provide a project with steps to reproduce the problem
Hi folks,
i had the same issue with latest local maven 3.9.5. I was looking at unsere CI System and in the last few weeks was the same problem but with the maven 3.9.3.
Because it was an AccesDeniedException i was thinking about Windows File System Policy or something like that. I was deleting the complete repository and build was again fine.
I will update you if problem continues or maybe not anymore.
It can be connected with https://issues.apache.org/jira/browse/MRESOLVER-372
Hi folks,
after testing a lot, we have discovered our IT Security department introduced a new antivirus (trendmicro) and i think it was the main reason for the problem.
This is not happening in the last few days but we didn't also any change. It was even funny, because after a failed build i was testing und manually run a new build and it was not failing.
So i suggest @chenfeg to check if something like that is happening also for you.
After diving into the problem again, it is right now clear.
Problem has to be with https://issues.apache.org/jira/browse/MRESOLVER-372 i was coming back to version 3.9.3 and problem is not yet happening.
Thanks @slawekjaranowski for the link and issue. Until next version with a fix, maybe 3.9.6? I will let run for a hole week our CI Pipelines with the version 3.9.3 and i will update all of you next week.
Yes, maven 3.9.6 is to be released very very soon (tomorrow?)
Thank you so much @cstamas. I was checking the next release version for 3.9.6. Our windows build server will be waiting for it! ;-)
Vote is here: https://lists.apache.org/thread/sc5rgz3qzm9b8b6gwg622xokpqpsxmyv
Feel free to test the binaries!
Thank you very much @cstamas for the vote and the binaries. I've just installed it in our CI Windows Server. It seems running pretty fine now und all the builds for the CI are running fine. Dev Team will be really happy with it. Lets see also the nightly builds. Many thanks to all of you and the devteam and specially to @slawekjaranowski because the link to MRESOLVER-372
Hi folks,
after setting/installing the new maven version 3.9.6, all builds are running now with and without wrapper fine for a week yet.
because @chenfeg started the issue with Maven 4.0.0.alpha5 i was checking if the alpha was updated too.
I am not sure if the problem/bug will be fixed into the alpha 9. But if so, could you @chenfeg test it? and eventually closing issue?.
Thanks a lot.
@harryssuperman The upcoming Maven 4.0.0-alpha-9 contains the fix as well (as it contains Resolver 2.0.0-alpha-3): https://issues.apache.org/jira/browse/MRESOLVER-372 https://issues.apache.org/jira/browse/MNG-7948
@cstamas Thanks a lot for the information and the Team too! Waiting expecting for the Maven 4!