apicurio-registry/3.1.4 package update
Commit: 5a80c41e62f1c63a124515233315e6798b3bfe24
📦 Build Failed: Missing Dependency
/home/build/common/src/main/java/io/apicurio/registry/utils/ConcurrentUtil.java:[53,70] package io.vertx.core does not exist
Build Details
| Category | Details |
|---|---|
| Build System | Maven |
| Failure Point | Maven compiler:compile phase - compiling 169 source files with javac |
Root Cause Analysis 🔍
The io.vertx.core package is not available on the classpath during compilation. The ConcurrentUtil.java file imports io.vertx.core but the required Vert.x Core dependency is either missing from the project's dependencies or not properly resolved.
🔍 Build failure fix suggestions
Found similar build failures that have been fixed in the past and analyzed them to suggest a fix:
Suggested Changes
File: Melange YAML environment section
- add_dependency (environment.contents.packages) Original:
environment:
contents:
packages:
- bash
- build-base
- busybox
- ca-certificates-bundle
- curl
- go
- icu
- maven
- nodejs-20
- npm
- openjdk-17-default-jdk
Replacement:
environment:
contents:
packages:
- bash
- build-base
- busybox
- ca-certificates-bundle
- curl
- go
- icu
- maven
- nodejs-20
- npm
- openjdk-17-default-jdk
- maven-vertx
Content:
Add Vert.x Core dependency to build environment
File: Maven build configuration
- modify_build_command (pipeline Build step) Original:
./mvnw clean install \
-Pprod \
-DskipTests \
-T$(nproc)C \
--no-snapshot-updates \
--no-transfer-progress \
--fail-fast
Replacement:
./mvnw clean install \
-Pprod \
-DskipTests \
-T$(nproc)C \
--no-snapshot-updates \
--no-transfer-progress \
--fail-fast \
-U
Content:
Add Maven dependency resolution flags to ensure all dependencies are properly resolved
Click to expand fix analysis
Analysis
No similar build failures were provided, but the error indicates a missing Vert.x Core dependency during Maven compilation. This is a common Java build issue where a required dependency is not properly declared in the project's pom.xml or the dependency resolution is failing. The error occurs when Java code imports io.vertx.core package but the corresponding JAR is not available on the classpath during compilation.
Click to expand fix explanation
Explanation
The build failure is caused by the missing io.vertx.core package during Maven compilation. The suggested fix addresses this by: 1) Adding the maven-vertx package to the build environment dependencies, which should provide the Vert.x Core libraries needed for compilation. 2) Adding the -U flag to Maven to force update of snapshots and releases, ensuring all dependencies are properly resolved. This approach ensures that the Vert.x dependencies are available in the build environment before Maven attempts to compile the Java sources that import io.vertx.core classes.
Click to expand alternative approaches
Alternative Approaches
- Check if the upstream project's pom.xml properly declares Vert.x dependencies and apply a patch to fix missing dependency declarations
- Investigate if the quarkus.patch file might be removing or modifying Vert.x dependencies and adjust the patch accordingly
- Use Maven dependency:resolve goal before compile to explicitly resolve all dependencies
- Check if there are version conflicts with Vert.x and force a specific compatible version
Was this comment helpful? Please use 👍 or 👎 reactions on this comment.