Uploaded image for project: 'Sentry'
  1. Sentry
  2. SENTRY-1459

Alter view with HMS Client fails with "java.lang.IllegalArgumentException: Can not create a Path from a null string"

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 1.8.0
    • Component/s: None
    • Labels:
      None

      Description

      2016-08-25 13:32:51,470 ERROR org.apache.hadoop.hive.metastore.RetryingHMSHandler: [pool-6-thread-69]: MetaException(message:java.lang.IllegalArgumentException: Can not create a Path from a null string)
      at org.apache.hadoop.hive.metastore.HiveMetaStore$HMSHandler.newMetaException(HiveMetaStore.java:5438)
      at org.apache.hadoop.hive.metastore.HiveMetaStore$HMSHandler.alter_table_core(HiveMetaStore.java:3470)
      at org.apache.hadoop.hive.metastore.HiveMetaStore$HMSHandler.alter_table_with_environment_context(HiveMetaStore.java:3430)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      at java.lang.reflect.Method.invoke(Method.java:606)
      at org.apache.hadoop.hive.metastore.RetryingHMSHandler.invokeInternal(RetryingHMSHandler.java:133)
      at org.apache.hadoop.hive.metastore.RetryingHMSHandler.invoke(RetryingHMSHandler.java:99)
      at com.sun.proxy.$Proxy20.alter_table_with_environment_context(Unknown Source)
      at org.apache.hadoop.hive.metastore.api.ThriftHiveMetastore$Processor$alter_table_with_environment_context.getResult(ThriftHiveMetastore.java:9469)
      at org.apache.hadoop.hive.metastore.api.ThriftHiveMetastore$Processor$alter_table_with_environment_context.getResult(ThriftHiveMetastore.java:9453)
      at org.apache.thrift.ProcessFunction.process(ProcessFunction.java:39)
      at org.apache.thrift.TBaseProcessor.process(TBaseProcessor.java:39)
      at org.apache.hadoop.hive.thrift.HadoopThriftAuthBridge$Server$TUGIAssumingProcessor$1.run(HadoopThriftAuthBridge.java:684)
      at org.apache.hadoop.hive.thrift.HadoopThriftAuthBridge$Server$TUGIAssumingProcessor$1.run(HadoopThriftAuthBridge.java:679)
      at java.security.AccessController.doPrivileged(Native Method)
      at javax.security.auth.Subject.doAs(Subject.java:415)
      at org.apache.hadoop.security.UserGroupInformation.doAs(UserGroupInformation.java:1671)
      at org.apache.hadoop.hive.thrift.HadoopThriftAuthBridge$Server$TUGIAssumingProcessor.process(HadoopThriftAuthBridge.java:679)
      at org.apache.thrift.server.TThreadPoolServer$WorkerProcess.run(TThreadPoolServer.java:285)
      at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145)
      at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615)
      at java.lang.Thread.run(Thread.java:745)
      Caused by: java.lang.IllegalArgumentException: Can not create a Path from a null string
      at org.apache.hadoop.fs.Path.checkPathArg(Path.java:123)
      at org.apache.hadoop.fs.Path.<init>(Path.java:135)
      at org.apache.sentry.core.common.utils.PathUtils.parseURI(PathUtils.java:110)
      at org.apache.sentry.core.common.utils.PathUtils.parseDFSURI(PathUtils.java:100)
      at org.apache.sentry.binding.metastore.MetastoreAuthzBinding.authorizeAlterTable(MetastoreAuthzBinding.java:284)
      at org.apache.sentry.binding.metastore.MetastoreAuthzBinding.onEvent(MetastoreAuthzBinding.java:188)
      at org.apache.hadoop.hive.metastore.HiveMetaStore$HMSHandler.firePreEvent(HiveMetaStore.java:2028)
      at org.apache.hadoop.hive.metastore.HiveMetaStore$HMSHandler.alter_table_core(HiveMetaStore.java:3449)
      ... 22 more
      

      Seems like we need to add a null path check here. See MetastoreAuthzBindingBase. A test case can be added in TestMetastoreEndToEnd for alter view.

        Attachments

        1. SENTRY-1459.001.patch
          2 kB
          Ankur Gupta
        2. SENTRY-1459.002.patch
          5 kB
          Ankur Gupta

          Issue Links

            Activity

              People

              • Assignee:
                ankur.gupta Ankur Gupta
                Reporter:
                sravya Sravya Tirukkovalur
              • Votes:
                0 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: