admin管理员组文章数量:1026989
I have some OSGi artifacts (Eclipse plugins) built using Tycho. Then I have some other project building a Debian package with those artifacts included (own MOJO). The OSGi artifacts are declared as simple POM dependencies in the Debian package project POM.
Everything worked well until now, when I switched from Tycho 1.7.0 to 2.7.5. I have to switch because I need some other feature ("wrapAsBundle"). In the dependency resolution phase there are now some artifacts not found in the repository (own hosted Artifactory) and the build fails. It seems strange that there is something *.eclipse-plugin pulled which does not exist in the repository.
Before changes:
[INFO] Downloading from xyz.repository.snapshot: /artifactory/xyz-snapshot/xyz/xyz.service.ticket/1.0.0-SNAPSHOT/maven-metadata.xml
[INFO] Downloaded from xyz.repository.snapshot: /artifactory/xyz-snapshot/xyz/xyz.service.ticket/1.0.0-SNAPSHOT/maven-metadata.xml (1.3 kB at 80 kB/s)
[INFO]
[INFO] --- maven-clean-plugin:2.5:clean (default-clean) @ xyz.os.runtime ---
After changes:
[DEBUG] Skipped remote request for xyz.service:xyz.service.ticket:1.0.0-SNAPSHOT/maven-metadata.xml, already updated during this session.
[DEBUG] Using transporter WagonTransporter with priority -1.0 for /artifactory/xyz-snapshot/
[DEBUG] Using connector BasicRepositoryConnector with priority 0.0 for /artifactory/xyz-snapshot/ with username=abc, password=***
[INFO] Downloading from xyz.repository.snapshot: /artifactory/xyz-snapshot/xyz/xyzmon.data/1.0.0-SNAPSHOT/xyzmon.data-1.0.0-SNAPSHOT.eclipse-plugin
[DEBUG] Writing tracking file /home/gitlab-runner/.m2/repository/xyz/common/xyzmon.data/1.0.0-SNAPSHOT/xyzmon.data-1.0.0-SNAPSHOT.eclipse-plugin.lastUpdated
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 6.942 s
[INFO] Finished at: 2024-11-15T21:36:23+01:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal on project xyz.os.runtime: Could not resolve dependencies for project xyz.os:xyz.os.runtime:debian:3.7.0.20241115213614-testing: Could not find artifact xyz.os.runtimemon:xyz.os.runtimemon.data:eclipse-plugin:1.0.0-SNAPSHOT in technology.xyz.repository.snapshot (/artifactory/xyz-snapshot/) -> [Help 1]
.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal on project xyz.os.runtime: Could not resolve dependencies for project xyz.os:xyz.os.runtime:debian:3.7.0.20241115213614-testing: Could not find artifact xyz.os.runtimemon:xyz.os.runtimemon.data:eclipse-plugin:1.0.0-SNAPSHOT in xyz.repository.snapshot (/artifactory/xyz-snapshot/)
at .apache.maven.lifecycle.internal.LifecycleDependencyResolver.getDependencies (LifecycleDependencyResolver.java:269)
at .apache.maven.lifecycle.internal.LifecycleDependencyResolver.resolveProjectDependencies (LifecycleDependencyResolver.java:147)
at .apache.maven.lifecycle.internal.MojoExecutor.ensureDependenciesAreResolved (MojoExecutor.java:248)
at .apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:202)
at .apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:156)
Tycho configuration:
<plugin>
<groupId>.eclipse.tycho</groupId>
<artifactId>tycho-compiler-plugin</artifactId>
<version>${tycho.version}</version>
</plugin>
<plugin>
<groupId>.eclipse.tycho</groupId>
<artifactId>tycho-maven-plugin</artifactId>
<version>${tycho.version}</version>
<extensions>true</extensions>
</plugin>
<plugin>
<groupId>.eclipse.tycho</groupId>
<artifactId>tycho-versions-plugin</artifactId>
<version>${tycho.version}</version>
</plugin>
<plugin>
<groupId>.eclipse.tycho</groupId>
<artifactId>target-platform-configuration</artifactId>
<version>${tycho.version}</version>
<configuration>
<pomDependencies>wrapAsBundle</pomDependencies>
</configuration>
</plugin>
I have some OSGi artifacts (Eclipse plugins) built using Tycho. Then I have some other project building a Debian package with those artifacts included (own MOJO). The OSGi artifacts are declared as simple POM dependencies in the Debian package project POM.
Everything worked well until now, when I switched from Tycho 1.7.0 to 2.7.5. I have to switch because I need some other feature ("wrapAsBundle"). In the dependency resolution phase there are now some artifacts not found in the repository (own hosted Artifactory) and the build fails. It seems strange that there is something *.eclipse-plugin pulled which does not exist in the repository.
Before changes:
[INFO] Downloading from xyz.repository.snapshot: https://repository.xyz/artifactory/xyz-snapshot/xyz/xyz.service.ticket/1.0.0-SNAPSHOT/maven-metadata.xml
[INFO] Downloaded from xyz.repository.snapshot: https://repository.xyz/artifactory/xyz-snapshot/xyz/xyz.service.ticket/1.0.0-SNAPSHOT/maven-metadata.xml (1.3 kB at 80 kB/s)
[INFO]
[INFO] --- maven-clean-plugin:2.5:clean (default-clean) @ xyz.os.runtime ---
After changes:
[DEBUG] Skipped remote request for xyz.service:xyz.service.ticket:1.0.0-SNAPSHOT/maven-metadata.xml, already updated during this session.
[DEBUG] Using transporter WagonTransporter with priority -1.0 for https://repository.xyz/artifactory/xyz-snapshot/
[DEBUG] Using connector BasicRepositoryConnector with priority 0.0 for https://repository.xyz/artifactory/xyz-snapshot/ with username=abc, password=***
[INFO] Downloading from xyz.repository.snapshot: https://repository.xyz/artifactory/xyz-snapshot/xyz/xyzmon.data/1.0.0-SNAPSHOT/xyzmon.data-1.0.0-SNAPSHOT.eclipse-plugin
[DEBUG] Writing tracking file /home/gitlab-runner/.m2/repository/xyz/common/xyzmon.data/1.0.0-SNAPSHOT/xyzmon.data-1.0.0-SNAPSHOT.eclipse-plugin.lastUpdated
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 6.942 s
[INFO] Finished at: 2024-11-15T21:36:23+01:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal on project xyz.os.runtime: Could not resolve dependencies for project xyz.os:xyz.os.runtime:debian:3.7.0.20241115213614-testing: Could not find artifact xyz.os.runtimemon:xyz.os.runtimemon.data:eclipse-plugin:1.0.0-SNAPSHOT in technology.xyz.repository.snapshot (https://repository.xyz/artifactory/xyz-snapshot/) -> [Help 1]
.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal on project xyz.os.runtime: Could not resolve dependencies for project xyz.os:xyz.os.runtime:debian:3.7.0.20241115213614-testing: Could not find artifact xyz.os.runtimemon:xyz.os.runtimemon.data:eclipse-plugin:1.0.0-SNAPSHOT in xyz.repository.snapshot (https://repository.xyz/artifactory/xyz-snapshot/)
at .apache.maven.lifecycle.internal.LifecycleDependencyResolver.getDependencies (LifecycleDependencyResolver.java:269)
at .apache.maven.lifecycle.internal.LifecycleDependencyResolver.resolveProjectDependencies (LifecycleDependencyResolver.java:147)
at .apache.maven.lifecycle.internal.MojoExecutor.ensureDependenciesAreResolved (MojoExecutor.java:248)
at .apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:202)
at .apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:156)
Tycho configuration:
<plugin>
<groupId>.eclipse.tycho</groupId>
<artifactId>tycho-compiler-plugin</artifactId>
<version>${tycho.version}</version>
</plugin>
<plugin>
<groupId>.eclipse.tycho</groupId>
<artifactId>tycho-maven-plugin</artifactId>
<version>${tycho.version}</version>
<extensions>true</extensions>
</plugin>
<plugin>
<groupId>.eclipse.tycho</groupId>
<artifactId>tycho-versions-plugin</artifactId>
<version>${tycho.version}</version>
</plugin>
<plugin>
<groupId>.eclipse.tycho</groupId>
<artifactId>target-platform-configuration</artifactId>
<version>${tycho.version}</version>
<configuration>
<pomDependencies>wrapAsBundle</pomDependencies>
</configuration>
</plugin>
Share
Improve this question
edited Nov 16, 2024 at 12:24
Martin
asked Nov 16, 2024 at 11:42
MartinMartin
1721 silver badge12 bronze badges
6
- 1 Note that the current version of Tycho is 4.0.10 – greg-449 Commented Nov 16, 2024 at 12:17
- Yes, but my projects are on Java 11. – Martin Commented Nov 16, 2024 at 12:21
- If I change the packaging of the related OSGi artifacts to 'jar' the everything in the debian project is resolved. However, then project dependency resolution fails. It must be something about changes with the packaging type and resolver. – Martin Commented Nov 16, 2024 at 12:48
- Seems related: github/eclipse-tycho/tycho/issues/2005 – Martin Commented Nov 16, 2024 at 13:13
- 2 The fact that your projects are on Java 11 should not prevent you from using the latest Tycho version. – howlger Commented Nov 16, 2024 at 16:51
1 Answer
Reset to default 0It seems this is fixed starting from Tycho 3.0.x: https://github/eclipse-tycho/tycho/pull/2011/commits/fdd9a7f09667106783048d61898d5d0091437975
replaceTypeWithExtension needs to be set to true then.
I have some OSGi artifacts (Eclipse plugins) built using Tycho. Then I have some other project building a Debian package with those artifacts included (own MOJO). The OSGi artifacts are declared as simple POM dependencies in the Debian package project POM.
Everything worked well until now, when I switched from Tycho 1.7.0 to 2.7.5. I have to switch because I need some other feature ("wrapAsBundle"). In the dependency resolution phase there are now some artifacts not found in the repository (own hosted Artifactory) and the build fails. It seems strange that there is something *.eclipse-plugin pulled which does not exist in the repository.
Before changes:
[INFO] Downloading from xyz.repository.snapshot: /artifactory/xyz-snapshot/xyz/xyz.service.ticket/1.0.0-SNAPSHOT/maven-metadata.xml
[INFO] Downloaded from xyz.repository.snapshot: /artifactory/xyz-snapshot/xyz/xyz.service.ticket/1.0.0-SNAPSHOT/maven-metadata.xml (1.3 kB at 80 kB/s)
[INFO]
[INFO] --- maven-clean-plugin:2.5:clean (default-clean) @ xyz.os.runtime ---
After changes:
[DEBUG] Skipped remote request for xyz.service:xyz.service.ticket:1.0.0-SNAPSHOT/maven-metadata.xml, already updated during this session.
[DEBUG] Using transporter WagonTransporter with priority -1.0 for /artifactory/xyz-snapshot/
[DEBUG] Using connector BasicRepositoryConnector with priority 0.0 for /artifactory/xyz-snapshot/ with username=abc, password=***
[INFO] Downloading from xyz.repository.snapshot: /artifactory/xyz-snapshot/xyz/xyzmon.data/1.0.0-SNAPSHOT/xyzmon.data-1.0.0-SNAPSHOT.eclipse-plugin
[DEBUG] Writing tracking file /home/gitlab-runner/.m2/repository/xyz/common/xyzmon.data/1.0.0-SNAPSHOT/xyzmon.data-1.0.0-SNAPSHOT.eclipse-plugin.lastUpdated
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 6.942 s
[INFO] Finished at: 2024-11-15T21:36:23+01:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal on project xyz.os.runtime: Could not resolve dependencies for project xyz.os:xyz.os.runtime:debian:3.7.0.20241115213614-testing: Could not find artifact xyz.os.runtimemon:xyz.os.runtimemon.data:eclipse-plugin:1.0.0-SNAPSHOT in technology.xyz.repository.snapshot (/artifactory/xyz-snapshot/) -> [Help 1]
.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal on project xyz.os.runtime: Could not resolve dependencies for project xyz.os:xyz.os.runtime:debian:3.7.0.20241115213614-testing: Could not find artifact xyz.os.runtimemon:xyz.os.runtimemon.data:eclipse-plugin:1.0.0-SNAPSHOT in xyz.repository.snapshot (/artifactory/xyz-snapshot/)
at .apache.maven.lifecycle.internal.LifecycleDependencyResolver.getDependencies (LifecycleDependencyResolver.java:269)
at .apache.maven.lifecycle.internal.LifecycleDependencyResolver.resolveProjectDependencies (LifecycleDependencyResolver.java:147)
at .apache.maven.lifecycle.internal.MojoExecutor.ensureDependenciesAreResolved (MojoExecutor.java:248)
at .apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:202)
at .apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:156)
Tycho configuration:
<plugin>
<groupId>.eclipse.tycho</groupId>
<artifactId>tycho-compiler-plugin</artifactId>
<version>${tycho.version}</version>
</plugin>
<plugin>
<groupId>.eclipse.tycho</groupId>
<artifactId>tycho-maven-plugin</artifactId>
<version>${tycho.version}</version>
<extensions>true</extensions>
</plugin>
<plugin>
<groupId>.eclipse.tycho</groupId>
<artifactId>tycho-versions-plugin</artifactId>
<version>${tycho.version}</version>
</plugin>
<plugin>
<groupId>.eclipse.tycho</groupId>
<artifactId>target-platform-configuration</artifactId>
<version>${tycho.version}</version>
<configuration>
<pomDependencies>wrapAsBundle</pomDependencies>
</configuration>
</plugin>
I have some OSGi artifacts (Eclipse plugins) built using Tycho. Then I have some other project building a Debian package with those artifacts included (own MOJO). The OSGi artifacts are declared as simple POM dependencies in the Debian package project POM.
Everything worked well until now, when I switched from Tycho 1.7.0 to 2.7.5. I have to switch because I need some other feature ("wrapAsBundle"). In the dependency resolution phase there are now some artifacts not found in the repository (own hosted Artifactory) and the build fails. It seems strange that there is something *.eclipse-plugin pulled which does not exist in the repository.
Before changes:
[INFO] Downloading from xyz.repository.snapshot: https://repository.xyz/artifactory/xyz-snapshot/xyz/xyz.service.ticket/1.0.0-SNAPSHOT/maven-metadata.xml
[INFO] Downloaded from xyz.repository.snapshot: https://repository.xyz/artifactory/xyz-snapshot/xyz/xyz.service.ticket/1.0.0-SNAPSHOT/maven-metadata.xml (1.3 kB at 80 kB/s)
[INFO]
[INFO] --- maven-clean-plugin:2.5:clean (default-clean) @ xyz.os.runtime ---
After changes:
[DEBUG] Skipped remote request for xyz.service:xyz.service.ticket:1.0.0-SNAPSHOT/maven-metadata.xml, already updated during this session.
[DEBUG] Using transporter WagonTransporter with priority -1.0 for https://repository.xyz/artifactory/xyz-snapshot/
[DEBUG] Using connector BasicRepositoryConnector with priority 0.0 for https://repository.xyz/artifactory/xyz-snapshot/ with username=abc, password=***
[INFO] Downloading from xyz.repository.snapshot: https://repository.xyz/artifactory/xyz-snapshot/xyz/xyzmon.data/1.0.0-SNAPSHOT/xyzmon.data-1.0.0-SNAPSHOT.eclipse-plugin
[DEBUG] Writing tracking file /home/gitlab-runner/.m2/repository/xyz/common/xyzmon.data/1.0.0-SNAPSHOT/xyzmon.data-1.0.0-SNAPSHOT.eclipse-plugin.lastUpdated
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 6.942 s
[INFO] Finished at: 2024-11-15T21:36:23+01:00
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal on project xyz.os.runtime: Could not resolve dependencies for project xyz.os:xyz.os.runtime:debian:3.7.0.20241115213614-testing: Could not find artifact xyz.os.runtimemon:xyz.os.runtimemon.data:eclipse-plugin:1.0.0-SNAPSHOT in technology.xyz.repository.snapshot (https://repository.xyz/artifactory/xyz-snapshot/) -> [Help 1]
.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal on project xyz.os.runtime: Could not resolve dependencies for project xyz.os:xyz.os.runtime:debian:3.7.0.20241115213614-testing: Could not find artifact xyz.os.runtimemon:xyz.os.runtimemon.data:eclipse-plugin:1.0.0-SNAPSHOT in xyz.repository.snapshot (https://repository.xyz/artifactory/xyz-snapshot/)
at .apache.maven.lifecycle.internal.LifecycleDependencyResolver.getDependencies (LifecycleDependencyResolver.java:269)
at .apache.maven.lifecycle.internal.LifecycleDependencyResolver.resolveProjectDependencies (LifecycleDependencyResolver.java:147)
at .apache.maven.lifecycle.internal.MojoExecutor.ensureDependenciesAreResolved (MojoExecutor.java:248)
at .apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:202)
at .apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:156)
Tycho configuration:
<plugin>
<groupId>.eclipse.tycho</groupId>
<artifactId>tycho-compiler-plugin</artifactId>
<version>${tycho.version}</version>
</plugin>
<plugin>
<groupId>.eclipse.tycho</groupId>
<artifactId>tycho-maven-plugin</artifactId>
<version>${tycho.version}</version>
<extensions>true</extensions>
</plugin>
<plugin>
<groupId>.eclipse.tycho</groupId>
<artifactId>tycho-versions-plugin</artifactId>
<version>${tycho.version}</version>
</plugin>
<plugin>
<groupId>.eclipse.tycho</groupId>
<artifactId>target-platform-configuration</artifactId>
<version>${tycho.version}</version>
<configuration>
<pomDependencies>wrapAsBundle</pomDependencies>
</configuration>
</plugin>
Share
Improve this question
edited Nov 16, 2024 at 12:24
Martin
asked Nov 16, 2024 at 11:42
MartinMartin
1721 silver badge12 bronze badges
6
- 1 Note that the current version of Tycho is 4.0.10 – greg-449 Commented Nov 16, 2024 at 12:17
- Yes, but my projects are on Java 11. – Martin Commented Nov 16, 2024 at 12:21
- If I change the packaging of the related OSGi artifacts to 'jar' the everything in the debian project is resolved. However, then project dependency resolution fails. It must be something about changes with the packaging type and resolver. – Martin Commented Nov 16, 2024 at 12:48
- Seems related: github/eclipse-tycho/tycho/issues/2005 – Martin Commented Nov 16, 2024 at 13:13
- 2 The fact that your projects are on Java 11 should not prevent you from using the latest Tycho version. – howlger Commented Nov 16, 2024 at 16:51
1 Answer
Reset to default 0It seems this is fixed starting from Tycho 3.0.x: https://github/eclipse-tycho/tycho/pull/2011/commits/fdd9a7f09667106783048d61898d5d0091437975
replaceTypeWithExtension needs to be set to true then.
本文标签: osgiMaven Tycho dependency resolution fails after switching from 170 to 275Stack Overflow
版权声明:本文标题:osgi - Maven Tycho dependency resolution fails after switching from 1.7.0 to 2.7.5 - Stack Overflow 内容由热心网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://it.en369.cn/questions/1745659054a2161776.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论