Skip to content

Conversation

@yhuai
Copy link
Contributor

@yhuai yhuai commented Aug 21, 2015

https://issues.apache.org/jira/browse/SPARK-10121

Looks like the problem is that if we add a jar through another thread, the thread handling the JDBC session will not get the latest classloader.

@yhuai
Copy link
Contributor Author

yhuai commented Aug 21, 2015

@liancheng I manually tested it and this looks like a right fix. How to write a unit test? Basically, I need to start the thriftserver and add a jar from another thread (e.g. spark shell) and test it in a jdbc connection.

@SparkQA
Copy link

SparkQA commented Aug 21, 2015

Test build #41392 has finished for PR 8368 at commit 2e9279a.

  • This patch passes all tests.
  • This patch merges cleanly.
  • This patch adds no public classes.

@SparkQA
Copy link

SparkQA commented Aug 21, 2015

Test build #41394 has finished for PR 8368 at commit 690d9cd.

  • This patch passes all tests.
  • This patch merges cleanly.
  • This patch adds the following public classes (experimental):
    • public static class AppExecId
    • public static class StoreVersion

@liancheng
Copy link
Contributor

This can be tested using HiveThriftJdbcTest.withMultipleConnectionJdbcStatement(). This method accepts zero or more Statement => Unit functions, and runs them within different JDBC sessions. Although these functions are executed sequentially, all the connections are established at the beginning, so different function are guaranteed to be executed in different thread.

@SparkQA
Copy link

SparkQA commented Aug 24, 2015

Test build #41437 has finished for PR 8368 at commit aac89f4.

  • This patch passes all tests.
  • This patch merges cleanly.
  • This patch adds no public classes.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@liancheng is this test good?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yeah, this LGTM.

@liancheng
Copy link
Contributor

LGTM. Merging to master and branch-1.5.

asfgit pushed a commit that referenced this pull request Aug 25, 2015
…provided by the conf of executionHive's state

https://issues.apache.org/jira/browse/SPARK-10121

Looks like the problem is that if we add a jar through another thread, the thread handling the JDBC session will not get the latest classloader.

Author: Yin Huai <[email protected]>

Closes #8368 from yhuai/SPARK-10121.

(cherry picked from commit a0c0aae)
Signed-off-by: Cheng Lian <[email protected]>
@asfgit asfgit closed this in a0c0aae Aug 25, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants