[FLINK-39783][table] Translate LATERAL SNAPSHOT to LateralSnapshotJoinOperator#28664
Open
fhueske wants to merge 2 commits into
Conversation
Generated-By: Claude Opus 4.7 (1M context)
Collaborator
cf44ef0 to
f0a7335
Compare
… operator Rewrites a join over a SNAPSHOT table function in a LATERAL clause into a dedicated FlinkLogicalLateralSnapshotJoin and converts it to a StreamPhysicalLateralSnapshotJoin / StreamExecLateralSnapshotJoin backed by the LateralSnapshotJoinOperator. The nodes derive their own output row type (materializing the build-side rowtime) and carry the SNAPSHOT arguments as fields. Generated-By: Claude Opus 4.8 (1M context)
f0a7335 to
3255f79
Compare
Contributor
Author
|
@flinkbot run azure |
1 task
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
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.
What is the purpose of the change
This PR is part of FLIP-579.
It adds the optimizer rules to translate the built-in SNAPSHOT function in a LATERAL context into a custom operator.
In this PR, the operator implementation is just a stub, see #28329 for the actual implementation.
Brief change log
FlinkLogicalLateralSnapshotJoinStreamPhysicalLateralSnapshotJoinStreamExecLateralSnapshotJoinLogicalCorrelateToJoinFromLateralSnapshotRuletranslates a SNAPSHOT table function call under a regular Join into aFlinkLogicalLateralSnapshotJoinStreamPhysicalLateralSnapshotJoinRuletranslates theFlinkLogicalLateralSnapshotJoininto aStreamPhysicalLateralSnapshotJoin. This is basically a 1:1 translation (adding hash-partitioning ).Special handling:
disableSystemArguments(true)is set on the SNAPSHOT function definition. Currently, this flag is not correctly handled (see FLINK-40079]. The current behavior is that system-args are not rejected but do also not affect the join.Verifying this change
Added unit tests checking plans and validations.
Does this pull request potentially affect one of the following parts:
@Public(Evolving): noDocumentation
Was generative AI tooling used to co-author this PR?
Co-authored-by: Claude Code 2.1.148 (Opus 4.7)