opensearch-project / opensearch-project/data-prepper

Consolidate CompressionOption enums

Open
#5,876 3 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

enhancement
Dominant language
Java
Stars
374
Forks
354
Avg merge
3d 18h
Merged PRs (30d)
8

Description

Is your feature request related to a problem? Please describe.
There are currently two CompressionOption enums providing similar compression functionality. One of these CompressionOptions is used for S3 pipelines and the other is being used for KafkaBuffer. When additional compression engines are added to one CompressionOption, these changes are not reflected in the other CompressionOption.

S3 CompressionOption: org.opensearch.dataprepper.plugins.sink.s3.compression
Codec/KafkaBuffer CompressionOption: org.opensearch.dataprepper.plugins.codec

Adding ZSTD compression functionality to KafkaBuffer did not provide additional ZSTD functionality in the S3 pipeline.

Ideally, the two enums should be consolidated to reduce duplicate code.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Compare the CompressionOption enum in org.opensearch.dataprepper.plugins.sink.s3.compression with the one in org.opensearch.dataprepper.plugins.codec, then trace their S3 pipeline and KafkaBuffer usages. Done means both pipelines use one consolidated enum and future compression engines are represented consistently.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
backend
Issue type
Refactor
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.