Repository: hive Updated Branches: refs/heads/master 0e446dd4d -> a7cf6549f
HIVE-15081: RetryingMetaStoreClient.getProxy(HiveConf, Boolean) doesn't match constructor of HiveMetaStoreClient (Rui reviewed by Sergey) Project: http://git-wip-us.apache.org/repos/asf/hive/repo Commit: http://git-wip-us.apache.org/repos/asf/hive/commit/a7cf6549 Tree: http://git-wip-us.apache.org/repos/asf/hive/tree/a7cf6549 Diff: http://git-wip-us.apache.org/repos/asf/hive/diff/a7cf6549 Branch: refs/heads/master Commit: a7cf6549f136efd65531f859c1e08cce26885b37 Parents: 0e446dd Author: Rui Li <[email protected]> Authored: Mon Oct 31 15:29:24 2016 +0800 Committer: Rui Li <[email protected]> Committed: Mon Oct 31 15:29:24 2016 +0800 ---------------------------------------------------------------------- .../java/org/apache/hadoop/hive/metastore/MetaStoreUtils.java | 2 +- .../apache/hadoop/hive/metastore/RetryingMetaStoreClient.java | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/hive/blob/a7cf6549/metastore/src/java/org/apache/hadoop/hive/metastore/MetaStoreUtils.java ---------------------------------------------------------------------- diff --git a/metastore/src/java/org/apache/hadoop/hive/metastore/MetaStoreUtils.java b/metastore/src/java/org/apache/hadoop/hive/metastore/MetaStoreUtils.java index 41385f7..9a4c61a 100644 --- a/metastore/src/java/org/apache/hadoop/hive/metastore/MetaStoreUtils.java +++ b/metastore/src/java/org/apache/hadoop/hive/metastore/MetaStoreUtils.java @@ -1647,7 +1647,7 @@ public class MetaStoreUtils { } for (int i = 0; i < parameterTypes.length; i++) { Class<?> clazz = parameterTypes[i]; - if (!(clazz.isInstance(initargs[i]))) { + if (initargs[i] != null && !(clazz.isInstance(initargs[i]))) { throw new IllegalArgumentException("Object : " + initargs[i] + " is not an instance of " + clazz); } http://git-wip-us.apache.org/repos/asf/hive/blob/a7cf6549/metastore/src/java/org/apache/hadoop/hive/metastore/RetryingMetaStoreClient.java ---------------------------------------------------------------------- diff --git a/metastore/src/java/org/apache/hadoop/hive/metastore/RetryingMetaStoreClient.java b/metastore/src/java/org/apache/hadoop/hive/metastore/RetryingMetaStoreClient.java index f0bd438..96d8248 100644 --- a/metastore/src/java/org/apache/hadoop/hive/metastore/RetryingMetaStoreClient.java +++ b/metastore/src/java/org/apache/hadoop/hive/metastore/RetryingMetaStoreClient.java @@ -84,8 +84,8 @@ public class RetryingMetaStoreClient implements InvocationHandler { public static IMetaStoreClient getProxy( HiveConf hiveConf, boolean allowEmbedded) throws MetaException { - return getProxy(hiveConf, new Class[]{HiveConf.class, Boolean.class}, - new Object[]{hiveConf, allowEmbedded}, null, HiveMetaStoreClient.class.getName() + return getProxy(hiveConf, new Class[]{HiveConf.class, HiveMetaHookLoader.class, Boolean.class}, + new Object[]{hiveConf, null, allowEmbedded}, null, HiveMetaStoreClient.class.getName() ); }
