Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fail to build Fabric8 :: Java generator :: Gradle Plugin #6163

Closed
jorsol opened this issue Jul 19, 2024 · 2 comments · Fixed by manusa/gradle-api-maven-plugin#51 or #6813
Closed

Fail to build Fabric8 :: Java generator :: Gradle Plugin #6163

jorsol opened this issue Jul 19, 2024 · 2 comments · Fixed by manusa/gradle-api-maven-plugin#51 or #6813
Assignees
Milestone

Comments

@jorsol
Copy link
Contributor

jorsol commented Jul 19, 2024

Describe the bug

Building the project using mvn clean package -DskipTests and fails with:

...
17:24:35.433 [INFO] Fabric8 :: Java generator :: Gradle Plugin ......... FAILURE [  0.082 s]
17:24:35.433 [INFO] Fabric8 :: Java generator :: Maven Plugin .......... SKIPPED
17:24:35.433 [INFO] Fabric8 :: Java generator :: Integration Tests ..... SKIPPED
17:24:35.433 [INFO] Fabric8 :: Java generator :: Benchmarks ............ SKIPPED
17:24:35.433 [INFO] Fabric8 :: Kubernetes :: HttpClient :: Vert.x ...... SKIPPED
17:24:35.433 [INFO] Fabric8 :: Kubernetes :: Dependency Compatibility :: Tests SKIPPED
17:24:35.433 [INFO] Fabric8 :: Kubernetes :: Bouncy Castle FIPS Compatibility :: Test SKIPPED
17:24:35.433 [INFO] Fabric8 :: Kubernetes :: Log4j Core components ..... SKIPPED
17:24:35.433 [INFO] Fabric8 :: Kubernetes :: HttpClient :: JDK ......... SKIPPED
17:24:35.433 [INFO] Fabric8 :: Kubernetes :: HttpClient :: Jetty ....... SKIPPED
17:24:35.433 [INFO] Fabric8 :: Kubernetes :: HttpClient Tests .......... SKIPPED
17:24:35.433 [INFO] Kube API Test Parent ............................... SKIPPED
17:24:35.433 [INFO] Kube API Test ...................................... SKIPPED
17:24:35.433 [INFO] Kube API Test - Client Injecting Support ........... SKIPPED
17:24:35.433 [INFO] ------------------------------------------------------------------------
17:24:35.433 [INFO] BUILD FAILURE
17:24:35.433 [INFO] ------------------------------------------------------------------------
17:24:35.433 [INFO] Total time:  08:01 min
17:24:35.433 [INFO] Finished at: 2024-07-19T17:24:35+02:00
17:24:35.433 [INFO] ------------------------------------------------------------------------
17:24:35.434 [ERROR] Failed to execute goal on project io.fabric8.java-generator.gradle.plugin: Could not resolve dependencies for project io.fabric8.java-generator:io.fabric8.java-generator.gradle.plugin:jar:7.0-SNAPSHOT
17:24:35.434 [ERROR] dependency: org.gradle:gradle-tooling-api:jar:8.5 (provided)
17:24:35.434 [ERROR] 	org.gradle:gradle-tooling-api:jar:8.5 was not found in https://repo1.maven.org/maven2/ during a previous attempt. This failure was cached in the local repository and resolution is not reattempted until the update interval of maven-central has elapsed or updates are forced
17:24:35.434 [ERROR] 	org.gradle:gradle-tooling-api:jar:8.5 was not found in https://repo.gradle.org/gradle/libs-releases-local/ during a previous attempt. This failure was cached in the local repository and resolution is not reattempted until the update interval of repo.gradle.org has elapsed or updates are forced
17:24:35.434 [ERROR] 	org.gradle:gradle-tooling-api:jar:8.5 was not found in https://repo.gradle.org/gradle/ext-releases-local/ during a previous attempt. This failure was cached in the local repository and resolution is not reattempted until the update interval of ext.repo.gradle.org has elapsed or updates are forced
17:24:35.434 [ERROR] 	org.gradle:gradle-tooling-api:jar:8.5 was not found in https://repo1.maven.org/maven2/ during a previous attempt. This failure was cached in the local repository and resolution is not reattempted until the update interval of sonatype-maven-org has elapsed or updates are forced
17:24:35.434 [ERROR] 	org.gradle:gradle-tooling-api:jar:8.5 was not found in https://maven-central-eu.storage-download.googleapis.com/maven2/ during a previous attempt. This failure was cached in the local repository and resolution is not reattempted until the update interval of google-maven-central has elapsed or updates are forced

Fabric8 Kubernetes Client version

SNAPSHOT

Steps to reproduce

mvn clean package -DskipTests

Expected behavior

Build success

Runtime

Kubernetes (vanilla)

Kubernetes API Server version

1.25.3@latest

Environment

Linux

Fabric8 Kubernetes Client Logs

No response

Additional context

No response

@manusa
Copy link
Member

manusa commented Jul 22, 2024

This is known problem with com.marcnuri.plugins:gradle-api-maven-plugin.

Originally tracked in https://quarkusio.zulipchat.com/#narrow/stream/187038-dev/topic/package.20org.2Egradle.2Ewrapper.20does.20not.20exist/

It happens because the content of one of the Gradle distribution jars is different if downloaded from Maven Central or the Gradle distribution itself.

Gradle exposes a tiny fraction of their distribution Jars in Maven Central. It also adds additional stuff to these Jars so there's no need to publish additional artifacts that contain some of the other required classes present in the standard distribution.

The gradle-api-maven-plugin downloads the jars from the standard Gradle distribution and places them in your local Maven repository.

If you're building Quarkus and the Fabric8 Kubernetes Client, depending on which project you built first, you might get these sort of problems when building the Gradle-related modules for either project.

A simple mvn -U to force the download of the Gradle dependencies should fix the issue. Keep in mind that if then you switch to Quarkus you might need to do that there too.

The problem will be fixed once manusa/gradle-api-maven-plugin#28 is merged.

Copy link

stale bot commented Nov 16, 2024

This issue has been automatically marked as stale because it has not had any activity since 90 days. It will be closed if no further activity occurs within 7 days. Thank you for your contributions!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment