-
Notifications
You must be signed in to change notification settings - Fork 3.5k
Write min/max statistics with truncation for strings in parquet #19038
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
raunaqmorarka
commented
Sep 14, 2023
lib/trino-parquet/src/main/java/io/trino/parquet/writer/ParquetMetadataUtils.java
Outdated
Show resolved
Hide resolved
sopel39
approved these changes
Sep 14, 2023
sopel39
reviewed
Sep 14, 2023
lib/trino-parquet/src/main/java/io/trino/parquet/writer/ParquetMetadataUtils.java
Outdated
Show resolved
Hide resolved
a0c91f9 to
28e897a
Compare
28e897a to
7ff2a3d
Compare
Contributor
|
Build is 🔴 |
7ff2a3d to
fb47ac6
Compare
findinpath
reviewed
Sep 15, 2023
lib/trino-parquet/src/main/java/io/trino/parquet/writer/ParquetMetadataUtils.java
Outdated
Show resolved
Hide resolved
Member
|
Let's make sure @ebyhr reviews this |
ebyhr
approved these changes
Sep 15, 2023
findepi
reviewed
Sep 20, 2023
lib/trino-parquet/src/main/java/io/trino/parquet/writer/ParquetMetadataUtils.java
Outdated
Show resolved
Hide resolved
findepi
reviewed
Sep 20, 2023
lib/trino-parquet/src/main/java/io/trino/parquet/writer/ParquetMetadataUtils.java
Outdated
Show resolved
Hide resolved
lib/trino-parquet/src/main/java/io/trino/parquet/writer/ParquetMetadataUtils.java
Outdated
Show resolved
Hide resolved
lib/trino-parquet/src/main/java/io/trino/parquet/writer/ParquetMetadataUtils.java
Outdated
Show resolved
Hide resolved
lib/trino-parquet/src/main/java/io/trino/parquet/writer/ParquetMetadataUtils.java
Outdated
Show resolved
Hide resolved
lib/trino-parquet/src/main/java/io/trino/parquet/writer/PrimitiveColumnWriter.java
Outdated
Show resolved
Hide resolved
lib/trino-parquet/src/test/java/io/trino/parquet/writer/TestParquetWriter.java
Outdated
Show resolved
Hide resolved
lib/trino-parquet/src/main/java/io/trino/parquet/writer/ParquetMetadataUtils.java
Outdated
Show resolved
Hide resolved
lib/trino-parquet/src/main/java/io/trino/parquet/writer/ParquetMetadataUtils.java
Outdated
Show resolved
Hide resolved
Member
|
Added a bunch of comments, the most important being
so you can start reading from these two |
a0895a2 to
c2dcfba
Compare
findepi
reviewed
Sep 26, 2023
lib/trino-parquet/src/main/java/io/trino/parquet/writer/ParquetMetadataUtils.java
Outdated
Show resolved
Hide resolved
lib/trino-parquet/src/main/java/io/trino/parquet/writer/ParquetMetadataUtils.java
Outdated
Show resolved
Hide resolved
lib/trino-parquet/src/main/java/io/trino/parquet/writer/ParquetMetadataUtils.java
Outdated
Show resolved
Hide resolved
lib/trino-parquet/src/main/java/io/trino/parquet/writer/PrimitiveColumnWriter.java
Outdated
Show resolved
Hide resolved
lib/trino-parquet/src/test/java/io/trino/parquet/writer/TestParquetWriter.java
Outdated
Show resolved
Hide resolved
c2dcfba to
104927c
Compare
findepi
approved these changes
Sep 26, 2023
lib/trino-parquet/src/main/java/io/trino/parquet/writer/PrimitiveColumnWriter.java
Outdated
Show resolved
Hide resolved
lib/trino-parquet/src/main/java/io/trino/parquet/writer/ParquetMetadataUtils.java
Outdated
Show resolved
Hide resolved
lib/trino-parquet/src/main/java/io/trino/parquet/writer/ParquetMetadataUtils.java
Outdated
Show resolved
Hide resolved
lib/trino-parquet/src/main/java/io/trino/parquet/writer/ParquetMetadataUtils.java
Outdated
Show resolved
Hide resolved
lib/trino-parquet/src/test/java/io/trino/parquet/writer/TestParquetWriter.java
Outdated
Show resolved
Hide resolved
The current logic skips writing min/max statistics if they are longer than 4Kb This is changed to write stats with truncation to allow readers to perform filtering
104927c to
e21e9b5
Compare
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
Currently the logic in
org.apache.parquet.format.converter.ParquetMetadataConverter#toParquetStatisticsskips writing min/max row-group statistics if they are longer than 4Kb. This is changed to write stats with truncation to allow readers to perform row-group pruning based on query predicates.Additional context and related issues
Related issue #19052
Parquet spec updated at apache/parquet-format#216 to clarify that truncation of min/max row-group stats is allowed
Release notes
( ) This is not user-visible or is docs only, and no release notes are required.
( ) Release notes are required. Please propose a release note for me.
(x) Release notes are required, with the following suggested text: