-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
[Kernel] Push predicate on partition values to checkpoint reader in state reconstruction #2872
[Kernel] Push predicate on partition values to checkpoint reader in state reconstruction #2872
Conversation
ff8e50a
to
8fd5440
Compare
kernel/kernel-api/src/main/java/io/delta/kernel/internal/util/PartitionUtils.java
Outdated
Show resolved
Hide resolved
* checkpoint files. | ||
* | ||
* @param predicate Predicate on partition columns. | ||
* @param partitionColMetadata Map of partition column name (in lower case) to its type. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
to its type
--> do we only need the type? like DataType? Or do we need the entire structfield?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I see we want the StructField. Could we replace to its type
with to its StructField
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM! Two minor comments
c3c06c5
to
773775b
Compare
…tate reconstruction (delta-io#2872) ## Description Converts the partition predicate into a filter on `add.partitionValues_parsed.<partitionPhysicalColName>`. This predicate is pushed to the Parquet reader when reading the checkpoint files during the state reconstruction. This helps prune reading checkpoint files that can't possibly have any scan files satisfying the given partition predicate. This can be extended in future to even support pushdown of predicate on data columns as well. ## How was this patch tested? Unittests
Description
Converts the partition predicate into a filter on
add.partitionValues_parsed.<partitionPhysicalColName>
. This predicate is pushed to the Parquet reader when reading the checkpoint files during the state reconstruction. This helps prune reading checkpoint files that can't possibly have any scan files satisfying the given partition predicate.This can be extended in future to even support pushdown of predicate on data columns as well.
How was this patch tested?
Unittests