Class SnapshotScannerHDFSAclController.SnapshotScannerHDFSAclStorage
java.lang.Object
org.apache.hadoop.hbase.security.access.SnapshotScannerHDFSAclController.SnapshotScannerHDFSAclStorage
- Enclosing class:
- SnapshotScannerHDFSAclController
-
Field Summary
Modifier and TypeFieldDescription(package private) static final byte[]
Add a new CF in HBase acl table to record if the HBase read permission is synchronized to related hfiles.private static final byte[]
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionprivate static void
addUserEntry
(Table t, String user, byte[] entry) (package private) static void
addUserGlobalHdfsAcl
(Table aclTable, String user) (package private) static void
addUserNamespaceHdfsAcl
(Table aclTable, String user, String namespace) (package private) static void
addUserTableHdfsAcl
(Connection connection, String user, TableName tableName) (package private) static void
addUserTableHdfsAcl
(Connection connection, Set<String> users, TableName tableName) (package private) static void
addUserTableHdfsAcl
(Table aclTable, String user, TableName tableName) private static void
deleteEntry
(Table aclTable, byte[] entry) (package private) static void
deleteNamespaceHdfsAcl
(Connection connection, String namespace) (package private) static void
deleteTableHdfsAcl
(Table aclTable, TableName tableName) private static void
deleteUserEntry
(Table aclTable, String user, byte[] entry) (package private) static void
deleteUserGlobalHdfsAcl
(Table aclTable, String user) (package private) static void
deleteUserNamespaceHdfsAcl
(Table aclTable, String user, String namespace) (package private) static void
deleteUserTableHdfsAcl
(Connection connection, Set<String> users, TableName tableName) (package private) static void
deleteUserTableHdfsAcl
(Table aclTable, String user, TableName tableName) getEntryUsers
(Table aclTable, byte[] entry) getTableUsers
(Table aclTable, TableName tableName) (package private) static List<byte[]>
getUserEntries
(Table aclTable, String userName) getUserNamespaceAndTable
(Table aclTable, String userName) private static boolean
hasUserEntry
(Table aclTable, String userName, byte[] entry) (package private) static boolean
hasUserGlobalHdfsAcl
(Table aclTable, String user) (package private) static boolean
hasUserNamespaceHdfsAcl
(Table aclTable, String user, String namespace) (package private) static boolean
hasUserTableHdfsAcl
(Table aclTable, String user, TableName tableName)
-
Field Details
-
HDFS_ACL_FAMILY
Add a new CF in HBase acl table to record if the HBase read permission is synchronized to related hfiles. The record has two usages: 1. check if we need to remove HDFS acls for a grant without READ permission(eg: grant user table read permission and then grant user table write permission without merging the existing permissions, in this case, need to remove HDFS acls); 2. skip some HDFS acl sync because it may be already set(eg: grant user table read permission and then grant user ns read permission; grant user table read permission and then grant user table write permission with merging the existing permissions). -
HDFS_ACL_VALUE
-
-
Constructor Details
-
SnapshotScannerHDFSAclStorage
-
-
Method Details
-
addUserGlobalHdfsAcl
- Throws:
IOException
-
addUserNamespaceHdfsAcl
static void addUserNamespaceHdfsAcl(Table aclTable, String user, String namespace) throws IOException - Throws:
IOException
-
addUserTableHdfsAcl
static void addUserTableHdfsAcl(Connection connection, Set<String> users, TableName tableName) throws IOException - Throws:
IOException
-
addUserTableHdfsAcl
static void addUserTableHdfsAcl(Connection connection, String user, TableName tableName) throws IOException - Throws:
IOException
-
addUserTableHdfsAcl
static void addUserTableHdfsAcl(Table aclTable, String user, TableName tableName) throws IOException - Throws:
IOException
-
addUserEntry
- Throws:
IOException
-
deleteUserGlobalHdfsAcl
- Throws:
IOException
-
deleteUserNamespaceHdfsAcl
static void deleteUserNamespaceHdfsAcl(Table aclTable, String user, String namespace) throws IOException - Throws:
IOException
-
deleteUserTableHdfsAcl
static void deleteUserTableHdfsAcl(Table aclTable, String user, TableName tableName) throws IOException - Throws:
IOException
-
deleteUserTableHdfsAcl
static void deleteUserTableHdfsAcl(Connection connection, Set<String> users, TableName tableName) throws IOException - Throws:
IOException
-
deleteUserEntry
- Throws:
IOException
-
deleteNamespaceHdfsAcl
- Throws:
IOException
-
deleteTableHdfsAcl
- Throws:
IOException
-
deleteEntry
- Throws:
IOException
-
getTableUsers
- Throws:
IOException
-
getEntryUsers
- Throws:
IOException
-
getUserNamespaceAndTable
static Pair<Set<String>,Set<TableName>> getUserNamespaceAndTable(Table aclTable, String userName) throws IOException - Throws:
IOException
-
getUserEntries
- Throws:
IOException
-
hasUserGlobalHdfsAcl
- Throws:
IOException
-
hasUserNamespaceHdfsAcl
static boolean hasUserNamespaceHdfsAcl(Table aclTable, String user, String namespace) throws IOException - Throws:
IOException
-
hasUserTableHdfsAcl
static boolean hasUserTableHdfsAcl(Table aclTable, String user, TableName tableName) throws IOException - Throws:
IOException
-
hasUserEntry
private static boolean hasUserEntry(Table aclTable, String userName, byte[] entry) throws IOException - Throws:
IOException
-