Skip to content

Commit d2927d8

Browse files
oheger-boschsschuberth
authored andcommitted
fix(Maven): Add the Maven Wagon HTTP provider
When fetching metadata for snapshot artifacts, Tycho seems to use Wagon to download this data from repositories. So, the Wagon HTTP provider needs to be present on the classpath. The exact circumstances when Tycho uses Wagon are unclear; but analyzing a real-life project failed with an error message that no wagon could be found supporting the protocol "https". Adding this artifact to the classpath fixed the issue. Signed-off-by: Oliver Heger <[email protected]>
1 parent e7d384a commit d2927d8

File tree

2 files changed

+6
-0
lines changed

2 files changed

+6
-0
lines changed

gradle/libs.versions.toml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,7 @@ slf4j = "2.0.17"
6767
springCore = "6.2.5"
6868
svnkit = "1.10.12"
6969
sw360Client = "17.0.1-m2"
70+
wagonHttp = "3.5.3"
7071
wiremock = "3.12.1"
7172
xmlutil = "0.90.3"
7273
xz = "1.10"
@@ -185,6 +186,7 @@ slf4j = { module = "org.slf4j:slf4j-api ", version.ref = "slf4j" }
185186
springCore = { module = "org.springframework:spring-core", version.ref = "springCore" }
186187
svnkit = { module = "com.tmatesoft.svnkit:svnkit", version.ref = "svnkit" }
187188
sw360Client = { module = "org.eclipse.sw360:client", version.ref = "sw360Client" }
189+
wagon-http = { module = "org.apache.maven.wagon:wagon-http", version.ref = "wagonHttp" }
188190
wiremock = { module = "org.wiremock:wiremock", version.ref = "wiremock" }
189191
xz = { module = "org.tukaani:xz", version.ref = "xz" }
190192

plugins/package-managers/maven/build.gradle.kts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -45,6 +45,10 @@ dependencies {
4545
// container automatically. They are required on the classpath for Maven dependency resolution to work.
4646
runtimeOnly(libs.bundles.mavenResolver)
4747

48+
// Under certain circumstances, Tycho uses Wagon to download metadata for SNAPSHOT artifacts. Therefore, at
49+
// least the wagon-http dependency should be available on the classpath.
50+
runtimeOnly(libs.wagon.http)
51+
4852
// TODO: Remove this once https://issues.apache.org/jira/browse/MNG-6561 is resolved.
4953
runtimeOnly(libs.maven.compat)
5054

0 commit comments

Comments
 (0)