[SPARK-XXXXX][SQL][TESTS] Add DSv2 temp view with stored plan tests#55540
Open
longvu-db wants to merge 2 commits intoapache:masterfrom
Open
[SPARK-XXXXX][SQL][TESTS] Add DSv2 temp view with stored plan tests#55540longvu-db wants to merge 2 commits intoapache:masterfrom
longvu-db wants to merge 2 commits intoapache:masterfrom
Conversation
Add 11 new tests to DataSourceV2DataFrameSuite that verify temp view behavior with stored plans when the underlying DSv2 table changes. Tests cover all 7 scenarios from the DSv2 table refresh design doc, including both session and external write variants. Co-authored-by: Isaac
Co-authored-by: Isaac
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 changes were proposed in this pull request?
Add 11 new tests to
DataSourceV2DataFrameSuitethat verify temporary view behavior with stored plans when the underlying DSv2 table changes. The tests cover all 7 scenarios from the DSv2 table refresh design doc:Each test creates a DSv2 table, inserts initial data, builds a temp view with a filter (
salary < 999) to demonstrate stored plan behavior, and verifies the view after table modifications.External writes use the direct catalog API (
loadTable+withData) to simulate writes from outside the session.Why are the changes needed?
The existing SPARK-53924 tests in
DataSourceV2DataFrameSuitecover basic schema change detection for temp views on DSv2 tables but are missing:These tests provide comprehensive coverage for the DSv2 table refresh design doc's Section 1 (Temp views with stored plans).
Does this PR introduce any user-facing change?
No. This PR only adds tests.
How was this patch tested?
All 11 new tests pass:
All 21 SPARK-53924 tests (10 existing + 11 new) pass with no regressions:
Was this patch authored or co-authored using generative AI tooling?
Yes.