[ https://issues.apache.org/jira/browse/MBUILDCACHE-63?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17735848#comment-17735848 ]
Tamas Cservenak commented on MBUILDCACHE-63: -------------------------------------------- Raw repository should not need {{dav:}} prefix, do not use it. Use plain (preferably modern) transport and that should do it. > Remote cache with Nexus raw repository does not work > ---------------------------------------------------- > > Key: MBUILDCACHE-63 > URL: https://issues.apache.org/jira/browse/MBUILDCACHE-63 > Project: Maven Build Cache Extension > Issue Type: Bug > Components: remote build cache > Affects Versions: 1.0.1 > Environment: Apache Maven 3.9.2 > (c9616018c7a021c1c39be70fb2843d6f5f9b8a1c) > Maven home: /opt/maven/apache-maven > Java version: 19.0.2, vendor: Eclipse Adoptium, runtime: > /opt/java/jdk-19.0.2+7 > Default locale: en_CA, platform encoding: UTF-8 > OS name: "linux", version: "5.19.0-43-generic", arch: "amd64", family: "unix" > Reporter: Ben Tatham > Priority: Major > > I set up a raw repository in Sonatype Nexus to use as the remote build cache. > It seems to connect ok, but the it gets a 404 when looking for the build > cache, and then does not seem to even attempt uploading it when the build is > complete (even though it does save the build cache locally). I assume this > means that the exception at start of the build is disabling the remote cache > being saved later in the build. > I have tried it with and without `dav:` prefix on the url, with same result. > -X gives no further details that I can see. > Let me know if there is anything else I can do to debug this. > {{[INFO] Attempting to restore project > ca.nanometrics.apollo.server:apollo-server-parent from build cache}} > {{[INFO] Downloading > dav:[https://*****/repository/build-cache/v1/ca.nanometrics.apollo.server/apollo-server-parent/db1314745382ad8b/buildinfo.xml|https://%2A%2A%2A%2A%2A/repository/build-cache/v1/ca.nanometrics.apollo.server/apollo-server-parent/db1314745382ad8b/buildinfo.xml]}} > {{[INFO] Cannot download > dav:[https://*****/repository/build-cache/v1/ca.nanometrics.apollo.server/apollo-server-parent/db1314745382ad8b/buildinfo.xml|https://%2A%2A%2A%2A%2A/repository/build-cache/v1/ca.nanometrics.apollo.server/apollo-server-parent/db1314745382ad8b/buildinfo.xml]}} > {{org.apache.maven.wagon.ResourceDoesNotExistException: resource missing at > [https://*****/repository/build-cache/v1/ca.nanometrics.apollo.server/apollo-server-parent/db1314745382ad8b/buildinfo.xml|https://%2A%2A%2A%2A%2A/repository/build-cache/v1/ca.nanometrics.apollo.server/apollo-server-parent/db1314745382ad8b/buildinfo.xml], > status: 404 > v1/ca.nanometrics.apollo.server/apollo-server-parent/db1314745382ad8b/buildinfo.xml}} > {{ at > org.apache.maven.wagon.shared.http.AbstractHttpClientWagon.fillInputData > (AbstractHttpClientWagon.java:1191)}} > {{ at > org.apache.maven.wagon.shared.http.AbstractHttpClientWagon.fillInputData > (AbstractHttpClientWagon.java:1140)}} > {{ at org.apache.maven.wagon.StreamWagon.getInputStream > (StreamWagon.java:126)}} > {{ at org.apache.maven.wagon.StreamWagon.getIfNewerToStream > (StreamWagon.java:226)}} > {{ at org.apache.maven.wagon.StreamWagon.getToStream > (StreamWagon.java:262)}} > {{ at > org.eclipse.aether.transport.wagon.WagonTransporter$GetTaskRunner.run > (WagonTransporter.java:427)}} > {{ at org.eclipse.aether.transport.wagon.WagonTransporter.execute > (WagonTransporter.java:367)}} > {{ at org.eclipse.aether.transport.wagon.WagonTransporter.get > (WagonTransporter.java:348)}} > {{ at > org.apache.maven.buildcache.RemoteCacheRepositoryImpl.getResourceContent > (RemoteCacheRepositoryImpl.java:151)}} > {{ at org.apache.maven.buildcache.RemoteCacheRepositoryImpl.findBuild > (RemoteCacheRepositoryImpl.java:108)}} > {{ at org.apache.maven.buildcache.LocalCacheRepositoryImpl.findBuild > (LocalCacheRepositoryImpl.java:169)}} > {{ at org.apache.maven.buildcache.CacheControllerImpl.findCachedBuild > (CacheControllerImpl.java:207)}} > {{ at org.apache.maven.buildcache.CacheControllerImpl.findCachedBuild > (CacheControllerImpl.java:180)}} > {{ at org.apache.maven.buildcache.BuildCacheMojosExecutionStrategy.execute > (BuildCacheMojosExecutionStrategy.java:117)}} > {{ at org.apache.maven.lifecycle.internal.MojoExecutor.execute > (MojoExecutor.java:160)}} > {{ at > org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject > (LifecycleModuleBuilder.java:105)}} > {{ at > org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject > (LifecycleModuleBuilder.java:73)}} > {{ at > org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build > (SingleThreadedBuilder.java:53)}} > {{ at org.apache.maven.lifecycle.internal.LifecycleStarter.execute > (LifecycleStarter.java:118)}} > {{ at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:261)}} > {{ at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:173)}} > {{ at org.apache.maven.DefaultMaven.execute (DefaultMaven.java:101)}} > {{ at org.apache.maven.cli.MavenCli.execute (MavenCli.java:910)}} > {{ at org.apache.maven.cli.MavenCli.doMain (MavenCli.java:283)}} > {{ at org.apache.maven.cli.MavenCli.main (MavenCli.java:206)}} > {{ at jdk.internal.reflect.DirectMethodHandleAccessor.invoke > (DirectMethodHandleAccessor.java:104)}} > {{ at java.lang.reflect.Method.invoke (Method.java:578)}} > {{ at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced > (Launcher.java:283)}} > {{ at org.codehaus.plexus.classworlds.launcher.Launcher.launch > (Launcher.java:226)}} > {{ at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode > (Launcher.java:407)}} > {{ at org.codehaus.plexus.classworlds.launcher.Launcher.main > (Launcher.java:348)}} > {{[INFO] Remote cache is incomplete or missing, trying local build for > ca.nanometrics.apollo.server:apollo-server-parent}} -- This message was sent by Atlassian Jira (v8.20.10#820010)