-
Notifications
You must be signed in to change notification settings - Fork 28.3k
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
[SPARK-20024] [SQL] [test-maven] SessionCatalog reset need to set the current database of ExternalCatalog #17354
Conversation
retest this please |
Test build #74854 has finished for PR 17354 at commit
|
retest this please |
Test build #74859 has started for PR 17354 at commit |
retest this please |
Test build #74860 has finished for PR 17354 at commit
|
Test build #74850 has finished for PR 17354 at commit
|
@gatorsmile Hi Sean, with this fix, do we still require the other fix in OrcSourceSuite ? We know that it can't hurt.. but it helps expose problems like this ? |
Yes, we can revert it back |
@gatorsmile Thanks a lot. |
retest this please |
1 similar comment
retest this please |
Test build #74868 has finished for PR 17354 at commit
|
Test build #74865 has finished for PR 17354 at commit
|
Test build #74892 has finished for PR 17354 at commit
|
Test build #74902 has finished for PR 17354 at commit
|
retest this please |
Test build #74900 has finished for PR 17354 at commit
|
@@ -226,6 +226,7 @@ class SessionCatalog( | |||
s"${globalTempViewManager.database}.viewName.") | |||
} | |||
requireDbExists(dbName) | |||
externalCatalog.setCurrentDatabase(dbName) |
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.
Hi, @gatorsmile .
Apache Spark 2.1.1 should have this fix, right?
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.
So far, everything works well without the fix. It only impacts the test cases, because when we always qualify the table names with the database names.
IMO, we should backport it to Spark 2.1.1.
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.
we always qualify the table names with the database names
It explains why we don't need this fix. IMO if it only impacts tests, we should fix it in tests.
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.
Let me move it to reset()
Test build #74904 has finished for PR 17354 at commit
|
LGTM |
Test build #74915 has finished for PR 17354 at commit
|
retest this please |
Test build #74928 has finished for PR 17354 at commit
|
Thanks! Merging to master. |
late LGTM~ |
What changes were proposed in this pull request?
SessionCatalog API setCurrentDatabase does not set the current database of the underlying ExternalCatalog. Thus, weird errors could come in the test suites after we call reset. We need to fix it.
So far, have not found the direct impact in the other code paths because we expect all the SessionCatalog APIs should always use the current database value we managed, unless some of code paths skip it. Thus, we fix it in the test-only function reset().
How was this patch tested?
Multiple test case failures are observed in mvn and add a test case in SessionCatalogSuite.