-
Notifications
You must be signed in to change notification settings - Fork 28.9k
[SPARK-17245] [SQL] [BRANCH-1.6] Do not rely on Hive's session state to retrieve HiveConf #14816
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
Closed
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
…to retrieve HiveConf
|
Test build #64439 has finished for PR 14816 at commit
|
Contributor
Author
|
test this please |
1 similar comment
Contributor
Author
|
test this please |
|
Test build #64443 has finished for PR 14816 at commit
|
Contributor
Author
|
test this please |
|
Test build #65014 has finished for PR 14816 at commit
|
Contributor
|
LGTM, merging to 1.6 |
asfgit
pushed a commit
that referenced
this pull request
Sep 7, 2016
… retrieve HiveConf ## What changes were proposed in this pull request? Right now, we rely on Hive's `SessionState.get()` to retrieve the HiveConf used by ClientWrapper. However, this conf is actually the HiveConf set with the `state`. There is a small chance that we are trying to use the Hive client in a new thread while the global client has not been created yet. In this case, `SessionState.get()` will return a `null`, which causes a NPE when we call `SessionState.get(). getConf `. Since the conf that we want is actually the conf we set to `state`. I am changing the code to just call `state.getConf` (this is also what Spark 2.0 does). ## How was this patch tested? I have not figured out a good way to reproduce this. Author: Yin Huai <[email protected]> Closes #14816 from yhuai/SPARK-17245.
Contributor
|
@yhuai, could you close this PR now that it's been merged? |
zzcclp
pushed a commit
to zzcclp/spark
that referenced
this pull request
Sep 8, 2016
… retrieve HiveConf ## What changes were proposed in this pull request? Right now, we rely on Hive's `SessionState.get()` to retrieve the HiveConf used by ClientWrapper. However, this conf is actually the HiveConf set with the `state`. There is a small chance that we are trying to use the Hive client in a new thread while the global client has not been created yet. In this case, `SessionState.get()` will return a `null`, which causes a NPE when we call `SessionState.get(). getConf `. Since the conf that we want is actually the conf we set to `state`. I am changing the code to just call `state.getConf` (this is also what Spark 2.0 does). ## How was this patch tested? I have not figured out a good way to reproduce this. Author: Yin Huai <[email protected]> Closes apache#14816 from yhuai/SPARK-17245. (cherry picked from commit 047bc3f)
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
What changes were proposed in this pull request?
Right now, we rely on Hive's
SessionState.get()to retrieve the HiveConf used by ClientWrapper. However, this conf is actually the HiveConf set with thestate. There is a small chance that we are trying to use the Hive client in a new thread while the global client has not been created yet. In this case,SessionState.get()will return anull, which causes a NPE when we callSessionState.get(). getConf. Since the conf that we want is actually the conf we set tostate. I am changing the code to just callstate.getConf(this is also what Spark 2.0 does).How was this patch tested?
I have not figured out a good way to reproduce this.