Skip to content

PHOENIX-7842 Reduce the shading contribution to build time#2460

Open
apurtell wants to merge 3 commits intoapache:masterfrom
apurtell:PHOENIX-7842
Open

PHOENIX-7842 Reduce the shading contribution to build time#2460
apurtell wants to merge 3 commits intoapache:masterfrom
apurtell:PHOENIX-7842

Conversation

@apurtell
Copy link
Copy Markdown
Contributor

@apurtell apurtell commented May 5, 2026

Phoenix's build time is dominated by four sibling shade executions (phoenix-client-embedded, phoenix-client-lite, phoenix-server, phoenix-mapreduce-byo-shaded-hbase). This change upgrades maven-shade-plugin to 3.6.2, which declares thread safety and fixes bugs, so mvn -T 1C parallelizes the four shades and they complete successfully, and turns off source-jar shading by default and reenables it under -Prelease.

It also makes phoenix-mapreduce-byo-shaded-hbase release-only. The module is moved out of the shade-and-assembly profile and into -Prelease, and phoenix-assembly is refactored so the mapreduce dependency is only pulled in only under -Prelease. BUILDING.md documents the new fast paths.

Verified end-to-end.

mvn -T 1C clean package builds 15 modules with no mapreduce jar in the tarball

mvn -T 1C -Prelease clean package builds all 16 with the mapreduce uberjar bundled.

The build time is reduced from 26:37 to 11:27 on my M4 MacBook, a 2.32x speedup.

@virajjasani virajjasani self-requested a review May 5, 2026 23:50
Copy link
Copy Markdown
Contributor

@richardantal richardantal left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM
Its always nice to have a faster build time.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants