Skip to content

HIVE-30039: Dependency resolution fails when project version has a su… - #6775

Open
sercanCyberVision wants to merge 1 commit into
apache:masterfrom
sercanCyberVision:dependency-resolution-fails
Open

HIVE-30039: Dependency resolution fails when project version has a su…#6775
sercanCyberVision wants to merge 1 commit into
apache:masterfrom
sercanCyberVision:dependency-resolution-fails

Conversation

@sercanCyberVision

Copy link
Copy Markdown
Contributor

PROBLEM
When Maven builds the reactor with a customized project version, for example 4.2.1-internal, the internal modules are built with that version:

[INFO] Reactor Summary for Hive 4.2.1-internal:

However, dependencies using ${hive.version} may still resolve to the original Hive version, such as 4.2.1:

Downloading from central: https://repo.maven.apache.org/maven2/org/apache/hive/hive-iceberg-handler/4.2.1/hive-iceberg-handler-4.2.1.jar

ROOT CAUSE

  1. Unlike the main POM, which defines <hive.version>${project.version}</hive.version>, the standalone-metastore POM has the Hive version hardcoded as <hive.version>4.2.1</hive.version>.
  2. In the standalone-metastore sub-modules, there are a few places where internal Hive module dependencies use ${hive.version} instead of ${project.version}.

SOLUTION

  1. Changed the hive.version property in standalone-metastore to make it consistent with the main POM.
  2. Changed the internal dependency versions from ${hive.version} to ${project.version}.

CHECKS
With the modified project version, I ran:

mvn dependency:tree -Dincludes=org.apache.hive:*

and verified that all internal Hive dependencies use the project version, ensuring that the corresponding artifacts are resolved from the Maven reactor.

@sonarqubecloud

Copy link
Copy Markdown

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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants