Skip to content

GH-43469: [Java] Change the default CompressionCodec.Factory to leverage compression support transparently - #43471

Merged
danepitkin merged 1 commit into
apache:mainfrom
hstack:compression-codec-service-provider
Jul 30, 2024
Merged

GH-43469: [Java] Change the default CompressionCodec.Factory to leverage compression support transparently#43471
danepitkin merged 1 commit into
apache:mainfrom
hstack:compression-codec-service-provider

Conversation

@ccciudatu

@ccciudatu ccciudatu commented Jul 29, 2024

Copy link
Copy Markdown
Contributor

Rationale for this change

Add compression support to Flight RPC and others by just including the arrow-compression jar in the module path (or classpath).

What changes are included in this PR?

Change the default compression factory to the new CompressionCodec.Factory.INSTANCE, a ServiceLoader-backed singleton that delegates to the best suited available implementation in the module/class path for each codec type.

Are these changes tested?

yes

Are there any user-facing changes?

No.

@ccciudatu
ccciudatu requested a review from lidavidm as a code owner July 29, 2024 09:35
@github-actions

Copy link
Copy Markdown

⚠️ GitHub issue #43469 has been automatically assigned in GitHub to PR creator.

@ccciudatu
ccciudatu force-pushed the compression-codec-service-provider branch 2 times, most recently from f852454 to 809f0ce Compare July 29, 2024 15:50
@ccciudatu
ccciudatu force-pushed the compression-codec-service-provider branch from 809f0ce to 263d3b1 Compare July 29, 2024 23:36
@vibhatha

Copy link
Copy Markdown
Contributor

cc @lidavidm needs approval for the CIs

@lidavidm lidavidm left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

CC @danepitkin @vibhatha as well; I think we will have to update various documentation/cookbook recipes since now you don't need explicit configuration

@github-actions github-actions Bot added awaiting merge Awaiting merge and removed awaiting review Awaiting review labels Jul 30, 2024
@danepitkin

Copy link
Copy Markdown
Member

CC @danepitkin @vibhatha as well; I think we will have to update various documentation/cookbook recipes since now you don't need explicit configuration

After grepping around, there is no documentation/cookbook that currently uses CompressionCodec. I agree, it would be good to add it.

@danepitkin danepitkin left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

LGTM!

@danepitkin

Copy link
Copy Markdown
Member

Added Cookbook issue here apache/arrow-cookbook#354

@conbench-apache-arrow

Copy link
Copy Markdown

After merging your PR, Conbench analyzed the 4 benchmarking runs that have been run so far on merge-commit 7e50097.

There were 6 benchmark results indicating a performance regression:

The full Conbench report has more details. It also includes information about 27 possible false positives for unstable benchmarks that are known to sometimes produce them.

@vibhatha

Copy link
Copy Markdown
Contributor

@danepitkin there are performance regressions 🤔

@ccciudatu
ccciudatu deleted the compression-codec-service-provider branch July 31, 2024 12:40
@danepitkin

Copy link
Copy Markdown
Member

Good catch. I took a look and the regressions are all in Arrow R. This looks unrelated to this PR so we can ignore.

@vibhatha

Copy link
Copy Markdown
Contributor

Thanks for checking it out @danepitkin

pribor pushed a commit to GlobalWebIndex/arrow that referenced this pull request Oct 24, 2025
… leverage compression support transparently (apache#43471)

### Rationale for this change

Add compression support to Flight RPC and others by just including the `arrow-compression` jar in the module path (or classpath).

### What changes are included in this PR?

Change the default compression factory to the new `CompressionCodec.Factory.INSTANCE`, a ServiceLoader-backed singleton that delegates to the best suited available implementation in the module/class path for each codec type.

### Are these changes tested?

yes

### Are there any user-facing changes?

No.
* GitHub Issue: apache#43469

Authored-by: Costi Ciudatu <ccciudatu@gmail.com>
Signed-off-by: Dane Pitkin <dpitkin@apache.org>
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.

4 participants