Uploaded image for project: 'Sentry (Retired)'
  1. Sentry (Retired)
  2. SENTRY-334

Handle errors more user firendly in db store when objects are not present.

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 1.3.0
    • 1.5.0
    • None
    • None

    Description

      For example show role grant group <groupName> throws a stack trace if the group has no roles granted:

      0: jdbc:hive2://localhost:10000/> show role grant group admin;
      Error: Error while processing statement: FAILED: Execution Error, return code 1 from org.apache.hadoop.hive.ql.exec.SentryGrantRevokeTask. Role: TListSentryRolesRequest(protocol_version:1, requestorUserName:hive, groupName:admin) couldn't be retrieved.. Server Stacktrace: org.apache.sentry.provider.db.SentryNoSuchObjectException: Group admin
      	at org.apache.sentry.provider.db.service.persistent.SentryStore.getMSentryRolesByGroupName(SentryStore.java:855)
      	at org.apache.sentry.provider.db.service.persistent.SentryStore.getTSentryRolesByGroupName(SentryStore.java:884)
      	at org.apache.sentry.provider.db.service.thrift.SentryPolicyStoreProcessor.list_sentry_roles_by_group(SentryPolicyStoreProcessor.java:326)
      	at org.apache.sentry.provider.db.service.thrift.SentryPolicyService$Processor$list_sentry_roles_by_group.getResult(SentryPolicyService.java:773)
      	at org.apache.sentry.provider.db.service.thrift.SentryPolicyService$Processor$list_sentry_roles_by_group.getResult(SentryPolicyService.java:758)
      	at sentry.org.apache.thrift.ProcessFunction.process(ProcessFunction.java:39)
      	at sentry.org.apache.thrift.TBaseProcessor.process(TBaseProcessor.java:39)
      	at sentry.org.apache.thrift.TMultiplexedProcessor.process(TMultiplexedProcessor.java:123)
      	at sentry.org.apache.thrift.server.TThreadPoolServer$WorkerProcess.run(TThreadPoolServer.java:244)
      	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) (state=08S01,code=1)
      

      Attachments

        Issue Links

          Activity

            People

              sravya Sravya Tirukkovalur
              sravya Sravya Tirukkovalur
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: