-
Notifications
You must be signed in to change notification settings - Fork 29k
[SPARK-35378][SQL][FOLLOWUP] isLocal should consider CommandResult #32963
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
Conversation
|
Kubernetes integration test unable to build dist. exiting with code: 1 |
|
Test build #139984 has finished for PR 32963 at commit
|
|
cc @cloud-fan |
| */ | ||
| def isLocal: Boolean = logicalPlan.isInstanceOf[LocalRelation] | ||
| def isLocal: Boolean = logicalPlan.isInstanceOf[LocalRelation] || | ||
| logicalPlan.isInstanceOf[CommandResult] |
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.
Could you add a test coverage for this, @beliefer ?
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.
+1, this API has no test at all, we can add one in DataFrameSuite
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.
Thank you for reminder.
|
Gentle ping, @beliefer . |
|
|
||
| test("isLocal should consider CommandResult and LocalRelation") { | ||
| withTable("t1") { | ||
| val df = sql("CREATE TABLE t USING PARQUET AS SELECT 1 as a") |
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.
can we use SHOW TABLES which returns data? Then we don't need to create a table and wrap with withTable.
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.
OK
|
Kubernetes integration test unable to build dist. exiting with code: 1 |
|
Kubernetes integration test starting |
|
Kubernetes integration test status failure |
dongjoon-hyun
left a comment
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.
+1, LGTM. Thank you, @beliefer and @cloud-fan .
|
Test build #140115 has finished for PR 32963 at commit
|
|
thanks, merging to master! |
|
@dongjoon-hyun @cloud-fan Thanks for review. |
|
Test build #140117 has finished for PR 32963 at commit
|
What changes were proposed in this pull request?
#32513 added the case class
CommandResultso as we can eagerly execute command locally. But we forgot to updateisLocalofDataset.Why are the changes needed?
Dataset.isLocalshould considerCommandResult.Does this PR introduce any user-facing change?
Yes. If the SQL plan is
CommandResult,Dataset.isLocalmust return true.How was this patch tested?
No test.