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-35226][SQL][FOLLOWUP] Fix test added in SPARK-35226 for DB2KrbIntegrationSuite #32632
Conversation
|
||
// Set the authentic krb5.conf but doesn't refresh config | ||
// so this assertion is expected to fail. | ||
intercept[Exception] { |
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.
DB2IntegrationSuite doesn't throw exception here so I'll remove this assertion.
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.
Why does db2 throw no exception in this test? cc: @gaborgsomogyi
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.
Anyway, since the other krb tests (e.g., PostgresKrbIntegrationSuite
) refer this test, I think we cannot remove it simply.
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.
If refreshKrb5Config
is not set to true, whether krb5.conf
is always read or not when a new connection is established can depend on the implementation for each JDBC driver.
We can remove the assertion because the remaining two assertions are important.
The second assertion ensures that refreshKrb5Config
enforces to refresh.
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.
You mean DB2KrbIntegrationSuite
instead of DB2IntegrationSuite
, right?
DB2IntegrationSuite doesn't throw exception here so I'll remove this assertion.
I also confirmed that DB2KrbIntegrationSuite
fails
[info] - SPARK-35226: JDBCOption should accept refreshKrb5Config parameter *** FAILED *** (1 second, 147 milliseconds)
[info] Expected exception java.lang.Exception to be thrown, but no exception was thrown (DockerKrbJDBCIntegrationSuite.scala:187)
[info] org.scalatest.exceptions.TestFailedException:
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.
Ah, Yes. I mean DB2KrbIntegrationSuite
.
cc: @dongjoon-hyun |
@@ -200,11 +188,11 @@ abstract class DockerKrbJDBCIntegrationSuite extends DockerJDBCIntegrationSuite | |||
.option("keytab", keytabFullPath) | |||
.option("principal", principal) | |||
.option("refreshKrb5Config", "true") | |||
.option("query", "SELECT 1") | |||
.option("query", "SELECT c0 FROM bar") |
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 use dbtable
instead?
Kubernetes integration test starting |
Kubernetes integration test status success |
Kubernetes integration test starting |
Kubernetes integration test status success |
Test build #138825 has finished for PR 32632 at commit
|
Test build #138827 has finished for PR 32632 at commit
|
retest this please. |
Kubernetes integration test starting |
Kubernetes integration test status success |
Test build #138830 has finished for PR 32632 at commit
|
Although this is a newly added test case issue, do you think this is a release blocker, @sarutak ? |
@dongjoon-hyun |
Yeah, I think we don't have to block the release. |
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, @sarutak and @maropu .
For the removed test coverage, I filed SPARK-35491.
Since this PR is a recovery of failed test case, I'll merge this first.
…IntegrationSuite ### What changes were proposed in this pull request? This PR fixes an test added in SPARK-35226 (#32344). ### Why are the changes needed? `SELECT 1` seems non-valid query for DB2. ### Does this PR introduce _any_ user-facing change? No. ### How was this patch tested? DB2KrbIntegrationSuite passes on my laptop. I also confirmed all the KrbIntegrationSuites pass with the following command. ``` build/sbt -Phive -Phive-thriftserver -Pdocker-integration-tests "testOnly org.apache.spark.sql.jdbc.*KrbIntegrationSuite" ``` Closes #32632 from sarutak/followup-SPARK-35226. Authored-by: Kousuke Saruta <sarutak@oss.nttdata.com> Signed-off-by: Dongjoon Hyun <dhyun@apple.com> (cherry picked from commit 1a43415) Signed-off-by: Dongjoon Hyun <dhyun@apple.com>
Oh, thank you, @HyukjinKwon ! I missed your comments while writing a review comments. |
Nono nothing to do with my comment. No worries 👍 |
…IntegrationSuite ### What changes were proposed in this pull request? This PR fixes an test added in SPARK-35226 (apache#32344). ### Why are the changes needed? `SELECT 1` seems non-valid query for DB2. ### Does this PR introduce _any_ user-facing change? No. ### How was this patch tested? DB2KrbIntegrationSuite passes on my laptop. I also confirmed all the KrbIntegrationSuites pass with the following command. ``` build/sbt -Phive -Phive-thriftserver -Pdocker-integration-tests "testOnly org.apache.spark.sql.jdbc.*KrbIntegrationSuite" ``` Closes apache#32632 from sarutak/followup-SPARK-35226. Authored-by: Kousuke Saruta <sarutak@oss.nttdata.com> Signed-off-by: Dongjoon Hyun <dhyun@apple.com> (cherry picked from commit 1a43415) Signed-off-by: Dongjoon Hyun <dhyun@apple.com>
What changes were proposed in this pull request?
This PR fixes an test added in SPARK-35226 (#32344).
Why are the changes needed?
SELECT 1
seems non-valid query for DB2.Does this PR introduce any user-facing change?
No.
How was this patch tested?
DB2KrbIntegrationSuite passes on my laptop.
I also confirmed all the KrbIntegrationSuites pass with the following command.