[ https://issues.apache.org/jira/browse/SENTRY-570?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Hao Hao updated SENTRY-570: --------------------------- Fix Version/s: 1.7.0 > Bug fixing for the test case "TestMetaStoreWithPigHCat" > ------------------------------------------------------- > > Key: SENTRY-570 > URL: https://issues.apache.org/jira/browse/SENTRY-570 > Project: Sentry > Issue Type: Test > Reporter: Colin Ma > Assignee: Colin Ma > Fix For: 1.7.0 > > Attachments: SENTRY-570.001.patch, SENTRY-570.002.patch > > > The policyFile is not set correctly. > Currently, the privilege is set by the following code, > "server=server1->db=db_1->{color:red}table=*{color}->action=SELECT", and the > value of table is "*". The method List<MSentryPrivilege> > getMSentryPrivileges(Set<String> roleNames, TSentryAuthorizable > authHierarchy) in SentryStore can't get this privilege. > {code} > .addPermissionsToRole(db_all_role, "server=server1->db=" + dbName) > .addPermissionsToRole("read_db_role", > "server=server1->db=" + dbName + "->table=*->action=SELECT") > {code} > The error setting cause the following exception, > {code} > try { > execPigLatin(USER2_1, pigServer, "store A into '" + dbName + "." + tabName > + "' using " > + HCatStorer.class.getName() + " ('part_col=part2');"); > fail("USER2_1 has no access to the metadata, exception will be > thrown."); > } catch (IOException e) { > // ignore the exception > } > {code} -- This message was sent by Atlassian JIRA (v6.3.4#6332)