-
Notifications
You must be signed in to change notification settings - Fork 28.5k
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-14786] Remove hive-cli dependency from hive subproject #12551
[SPARK-14786] Remove hive-cli dependency from hive subproject #12551
Conversation
<configuration> | ||
<rules> | ||
<bannedDependencies> | ||
<excludes combine.children="append"> |
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.
To verify that this does the correct thing, see
mvn -Phive -pl :spark-hive_2.11 help:effective-pom
LGTM pending Jenkins. |
@@ -110,10 +109,20 @@ private[hive] class HiveClientImpl( | |||
} | |||
} | |||
|
|||
def isCliSessionState(state: SessionState): Boolean = { | |||
var temp: Class[_] = state.getClass |
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.
In a test, this ended up failing with an NPE so I guess that the comment on line 114 / 123 is incorrect :(
LGTM |
Test build #56455 has finished for PR 12551 at commit
|
Test build #56453 has finished for PR 12551 at commit
|
Jenkins, retest this please. |
Test build #56470 has finished for PR 12551 at commit
|
Merging in master. |
The
hive
subproject currently depends onhive-cli
in order to perform a check to see whether aSessionState
is an instance oforg.apache.hadoop.hive.cli.CliSessionState
(see #9589). The introduction of thishive-cli
dependency has caused problems for users whose Hive metastore JAR classpaths don't include thehive-cli
classes (such as in #11495).This patch removes this dependency on
hive-cli
and replaces theisInstanceOf
check by reflection. I added a Maven Enforcer rule to banhive-cli
from thehive
subproject in order to make sure that this dependency is not accidentally reintroduced./cc @rxin @yhuai @adrian-wang @preecet