Uh oh!
There was an error while loading. Please reload this page.
[SPARK-2087] [SQL] Multiple thriftserver sessions with different HiveContext instances - #4382
[SPARK-2087] [SQL] Multiple thriftserver sessions with different HiveContext instances#4382chenghao-intel wants to merge 1 commit into
Conversation
SparkQA
commented
Feb 5, 2015
Test build #26816 has started for PR 4382 at commit
|
chenghao-intel
commented
Feb 5, 2015
@liancheng Do you have any idea how to collect the thrift sever logs in the unit test? It says timeout exception, and I believe either port error or the server process exited due to some error (like the create the hive metastore client failure). |
guowei2
commented
Feb 5, 2015
@chenghao-intel |
chenghao-intel
commented
Feb 5, 2015
@guowei2 Probably no. HiveContext has it's own internal metastore (temp metastore), |
SparkQA
commented
Feb 5, 2015
Test build #26816 has finished for PR 4382 at commit
|
AmplabJenkins
commented
Feb 5, 2015
Test PASSed. |
chenghao-intel
commented
Feb 5, 2015
Seems |
mallman
commented
Feb 5, 2015
FWIW I'd like to add my two cents. The main piece of functionality the installation at my company would benefit from is independent user sessions. I'm not familiar enough with the source to say exactly what that means in terms of a source patch, but one of the key use cases is the ability to set the session default database ("use ") and SQLConf settings independent of other beeline connections. Right now, setting the database sets it across all connections and that is a major impediment to wider use of a shared thriftserver. Cheers! |
chenghao-intel
commented
Feb 6, 2015
@mallman this PR exactly aims to fix the bug you mentioned, and it passed the tested in my local machine. However, I am still figuring out some of the unit testing failures, hopefully I can update the title by removing the "WIP" soon. |
chenghao-intel
commented
Feb 6, 2015
@liancheng Seems HiveThriftServer2Suite didn't run, is it disabled by default? |
liancheng
commented
Feb 10, 2015
@chenghao-intel This is just fixed by #4486. |
chenghao-intel
commented
Feb 10, 2015
Should I retest this? |
chenghao-intel
commented
Feb 10, 2015
test this please. |
liancheng
commented
Feb 10, 2015
HiveThriftServer2Suite timeout is also fixed, please refer to #4484. |
liancheng
commented
Feb 10, 2015
Yeah, you should retest. |
SparkQA
commented
Feb 10, 2015
Test build #27143 has started for PR 4382 at commit
|
SparkQA
commented
Feb 10, 2015
Test build #27143 has finished for PR 4382 at commit
|
AmplabJenkins
commented
Feb 10, 2015
Test PASSed. |
chenghao-intel
commented
Feb 10, 2015
@liancheng Seems the |
liancheng
commented
Feb 10, 2015
retest this please |
SparkQA
commented
Feb 10, 2015
Test build #27158 has started for PR 4382 at commit
|
SparkQA
commented
Feb 10, 2015
Test build #27158 has finished for PR 4382 at commit
|
AmplabJenkins
commented
Feb 10, 2015
Test PASSed. |
liancheng
commented
Feb 10, 2015
@chenghao-intel The biggest issue I see in this PR is that users can no longer share cached tables, which breaks many existing use scenarios. I'm afraid it may require major efforts to support both multi-session and cache sharing. I can think of two alternatives:
|
chenghao-intel
commented
Feb 11, 2015
Yeah, I can understand people want to share the cached table among multi-sessions, is there any potential requirement that people just want to keep the 'temp' table visibility within the HiveContext (will not share with the other session)? |
guowei2
commented
Feb 12, 2015
I agree with liancheng, user want to share cached tables in many cases. |
403d6ec to
73922aeCompareSparkQA
commented
Feb 12, 2015
Test build #27326 has started for PR 4382 at commit
|
chenghao-intel
commented
Feb 12, 2015
I agree with @liancheng, too, both code and description are updated. |
SparkQA
commented
Feb 12, 2015
Test build #27326 has finished for PR 4382 at commit
|
AmplabJenkins
commented
Feb 12, 2015
Test FAILed. |
chenghao-intel
commented
Feb 12, 2015
Seems failure due to the irrelevant code. |
chenghao-intel
commented
Feb 12, 2015
retest this please |
SparkQA
commented
Feb 12, 2015
Test build #27328 has started for PR 4382 at commit
|
SparkQA
commented
Feb 12, 2015
Test build #27328 has finished for PR 4382 at commit
|
AmplabJenkins
commented
Feb 12, 2015
Test FAILed. |
73922ae to
9d3b296CompareSparkQA
commented
Feb 15, 2015
Test build #27501 has started for PR 4382 at commit
|
SparkQA
commented
Feb 15, 2015
Test build #27501 has finished for PR 4382 at commit
|
AmplabJenkins
commented
Feb 15, 2015
Test FAILed. |
9d3b296 to
197e806CompareSparkQA
commented
Feb 22, 2015
Test build #27830 has started for PR 4382 at commit
|
SparkQA
commented
Feb 22, 2015
Test build #27830 has finished for PR 4382 at commit
|
AmplabJenkins
commented
Feb 22, 2015
Test PASSed. |
chenghao-intel
commented
Feb 23, 2015
/cc @liancheng can you review this for me? |
chenghao-intel
commented
Feb 25, 2015
/cc @liancheng@marmbrus can you give some high level comments? and then I can start the rebasing (again) |
liancheng
commented
Feb 25, 2015
Hey @chenghao-intel, thanks for working on this, AFAIK this is a pain point for many Spark SQL users who would like to put HiveThriftServer2 into production. Also had a discussion with @marmbrus about this recently. As we've discussed offline, instead of changing
The benefits of this approach are:
|
chenghao-intel
commented
Feb 25, 2015
@liancheng thank you very much for the so detailed comment! Actually I am quite fighting with the 2 approaches: The main reasons I choice the later approach is people can create arbitrary number of Whatever approach we take, it's intuitive that the What do you think? |
tianyi
commented
Mar 3, 2015
@chenghao-intel I'm little confusing about why people have to create multiple |
liancheng
commented
Mar 3, 2015
@chenghao-intel I'm posting the summary of our offline discussion here for future reference:
|
SparkQA
commented
Mar 9, 2015
Test build #28377 has started for PR 4382 at commit
|
SparkQA
commented
Mar 9, 2015
Test build #28377 has finished for PR 4382 at commit
|
AmplabJenkins
commented
Mar 9, 2015
Test PASSed. |
chenghao-intel
commented
Mar 17, 2015
Closing it since #4885 has been merged. |
Within thriftserver mode, only a single
HiveContextinstance for the process, and it leads tosqlconfobject shared across multiple user sessions.In order to isolate the
sqlconffor each user session, we create new HiveContext instance for each of the user session. However, we also want keep the existed logic like multiple users will share the same catalog and cache, hence I pull out thecatalog,cachemanageras well asfunctionRegistryas global unique instance.