Search in sources :

Example 6 with MTableColumnPrivilege

use of org.apache.hadoop.hive.metastore.model.MTableColumnPrivilege in project hive by apache.

the class ObjectStore method listPrincipalMTableColumnGrants.

private List<MTableColumnPrivilege> listPrincipalMTableColumnGrants(String principalName, PrincipalType principalType, String catName, String dbName, String tableName, String columnName, String authorizer) {
    boolean success = false;
    Query query = null;
    tableName = normalizeIdentifier(tableName);
    dbName = normalizeIdentifier(dbName);
    columnName = normalizeIdentifier(columnName);
    List<MTableColumnPrivilege> mSecurityColList = new ArrayList<>();
    try {
        LOG.debug("Executing listPrincipalTableColumnGrants");
        openTransaction();
        List<MTableColumnPrivilege> mPrivs;
        if (authorizer != null) {
            String queryStr = "principalName == t1 && principalType == t2 && " + "table.tableName == t3 && table.database.name == t4 &&  " + "table.database.catalogName == t5 && columnName == t6 && authorizer == t7";
            query = pm.newQuery(MTableColumnPrivilege.class, queryStr);
            query.declareParameters("java.lang.String t1, java.lang.String t2, java.lang.String t3, " + "java.lang.String t4, java.lang.String t5, java.lang.String t6, java.lang.String t7");
            mPrivs = (List<MTableColumnPrivilege>) query.executeWithArray(principalName, principalType.toString(), tableName, dbName, catName, columnName, authorizer);
        } else {
            String queryStr = "principalName == t1 && principalType == t2 && " + "table.tableName == t3 && table.database.name == t4 &&  " + "table.database.catalogName == t5 && columnName == t6 ";
            query = pm.newQuery(MTableColumnPrivilege.class, queryStr);
            query.declareParameters("java.lang.String t1, java.lang.String t2, java.lang.String t3, " + "java.lang.String t4, java.lang.String t5, java.lang.String t6");
            mPrivs = (List<MTableColumnPrivilege>) query.executeWithArray(principalName, principalType.toString(), tableName, dbName, catName, columnName);
        }
        pm.retrieveAll(mPrivs);
        success = commitTransaction();
        mSecurityColList.addAll(mPrivs);
        LOG.debug("Done retrieving all objects for listPrincipalTableColumnGrants");
    } finally {
        rollbackAndCleanup(success, query);
    }
    return mSecurityColList;
}
Also used : ScheduledQuery(org.apache.hadoop.hive.metastore.api.ScheduledQuery) Query(javax.jdo.Query) MScheduledQuery(org.apache.hadoop.hive.metastore.model.MScheduledQuery) ArrayList(java.util.ArrayList) MTableColumnPrivilege(org.apache.hadoop.hive.metastore.model.MTableColumnPrivilege)

Example 7 with MTableColumnPrivilege

use of org.apache.hadoop.hive.metastore.model.MTableColumnPrivilege in project hive by apache.

the class ObjectStore method revokePrivileges.

@Override
public boolean revokePrivileges(PrivilegeBag privileges, boolean grantOption) throws InvalidObjectException, MetaException, NoSuchObjectException {
    boolean committed = false;
    try {
        openTransaction();
        List<Object> persistentObjs = new ArrayList<>();
        List<HiveObjectPrivilege> privilegeList = privileges.getPrivileges();
        if (CollectionUtils.isNotEmpty(privilegeList)) {
            Iterator<HiveObjectPrivilege> privIter = privilegeList.iterator();
            while (privIter.hasNext()) {
                HiveObjectPrivilege privDef = privIter.next();
                HiveObjectRef hiveObject = privDef.getHiveObject();
                String privilegeStr = privDef.getGrantInfo().getPrivilege();
                if (privilegeStr == null || privilegeStr.trim().equals("")) {
                    continue;
                }
                String[] privs = privilegeStr.split(",");
                String userName = privDef.getPrincipalName();
                PrincipalType principalType = privDef.getPrincipalType();
                String catName = hiveObject.isSetCatName() ? hiveObject.getCatName() : getDefaultCatalog(conf);
                if (hiveObject.getObjectType() == HiveObjectType.GLOBAL) {
                    List<MGlobalPrivilege> mSecUser = this.listPrincipalMGlobalGrants(userName, principalType);
                    boolean found = false;
                    for (String privilege : privs) {
                        for (MGlobalPrivilege userGrant : mSecUser) {
                            String userGrantPrivs = userGrant.getPrivilege();
                            if (privilege.equals(userGrantPrivs)) {
                                found = true;
                                if (grantOption) {
                                    if (userGrant.getGrantOption()) {
                                        userGrant.setGrantOption(false);
                                    } else {
                                        throw new MetaException("User " + userName + " does not have grant option with privilege " + privilege);
                                    }
                                }
                                persistentObjs.add(userGrant);
                                break;
                            }
                        }
                        if (!found) {
                            throw new InvalidObjectException("No user grant found for privileges " + privilege);
                        }
                    }
                } else if (hiveObject.getObjectType() == HiveObjectType.DATABASE) {
                    MDatabase dbObj = getMDatabase(catName, hiveObject.getDbName());
                    String db = hiveObject.getDbName();
                    boolean found = false;
                    List<MDBPrivilege> dbGrants = this.listPrincipalMDBGrants(userName, principalType, catName, db);
                    for (String privilege : privs) {
                        for (MDBPrivilege dbGrant : dbGrants) {
                            String dbGrantPriv = dbGrant.getPrivilege();
                            if (privilege.equals(dbGrantPriv)) {
                                found = true;
                                if (grantOption) {
                                    if (dbGrant.getGrantOption()) {
                                        dbGrant.setGrantOption(false);
                                    } else {
                                        throw new MetaException("User " + userName + " does not have grant option with privilege " + privilege);
                                    }
                                }
                                persistentObjs.add(dbGrant);
                                break;
                            }
                        }
                        if (!found) {
                            throw new InvalidObjectException("No database grant found for privileges " + privilege + " on database " + db);
                        }
                    }
                } else if (hiveObject.getObjectType() == HiveObjectType.DATACONNECTOR) {
                    MDataConnector dCObj = getMDataConnector(hiveObject.getObjectName());
                    String dc = hiveObject.getObjectName();
                    boolean found = false;
                    List<MDCPrivilege> dcGrants = this.listPrincipalMDCGrants(userName, principalType, catName, dc);
                    for (String privilege : privs) {
                        for (MDCPrivilege dcGrant : dcGrants) {
                            String dcGrantPriv = dcGrant.getPrivilege();
                            if (privilege.equals(dcGrantPriv)) {
                                found = true;
                                if (grantOption) {
                                    if (dcGrant.getGrantOption()) {
                                        dcGrant.setGrantOption(false);
                                    } else {
                                        throw new MetaException("User " + userName + " does not have grant option with privilege " + privilege);
                                    }
                                }
                                persistentObjs.add(dcGrant);
                                break;
                            }
                        }
                        if (!found) {
                            throw new InvalidObjectException("No dataconnector grant found for privileges " + privilege + " on data connector " + dc);
                        }
                    }
                } else if (hiveObject.getObjectType() == HiveObjectType.TABLE) {
                    boolean found = false;
                    List<MTablePrivilege> tableGrants = this.listAllMTableGrants(userName, principalType, catName, hiveObject.getDbName(), hiveObject.getObjectName());
                    for (String privilege : privs) {
                        for (MTablePrivilege tabGrant : tableGrants) {
                            String tableGrantPriv = tabGrant.getPrivilege();
                            if (privilege.equalsIgnoreCase(tableGrantPriv)) {
                                found = true;
                                if (grantOption) {
                                    if (tabGrant.getGrantOption()) {
                                        tabGrant.setGrantOption(false);
                                    } else {
                                        throw new MetaException("User " + userName + " does not have grant option with privilege " + privilege);
                                    }
                                }
                                persistentObjs.add(tabGrant);
                                break;
                            }
                        }
                        if (!found) {
                            throw new InvalidObjectException("No grant (" + privilege + ") found " + " on table " + hiveObject.getObjectName() + ", database is " + hiveObject.getDbName());
                        }
                    }
                } else if (hiveObject.getObjectType() == HiveObjectType.PARTITION) {
                    boolean found = false;
                    Table tabObj = this.getTable(catName, hiveObject.getDbName(), hiveObject.getObjectName(), null);
                    String partName = null;
                    if (hiveObject.getPartValues() != null) {
                        partName = Warehouse.makePartName(tabObj.getPartitionKeys(), hiveObject.getPartValues());
                    }
                    List<MPartitionPrivilege> partitionGrants = this.listPrincipalMPartitionGrants(userName, principalType, catName, hiveObject.getDbName(), hiveObject.getObjectName(), partName);
                    for (String privilege : privs) {
                        for (MPartitionPrivilege partGrant : partitionGrants) {
                            String partPriv = partGrant.getPrivilege();
                            if (partPriv.equalsIgnoreCase(privilege)) {
                                found = true;
                                if (grantOption) {
                                    if (partGrant.getGrantOption()) {
                                        partGrant.setGrantOption(false);
                                    } else {
                                        throw new MetaException("User " + userName + " does not have grant option with privilege " + privilege);
                                    }
                                }
                                persistentObjs.add(partGrant);
                                break;
                            }
                        }
                        if (!found) {
                            throw new InvalidObjectException("No grant (" + privilege + ") found " + " on table " + tabObj.getTableName() + ", partition is " + partName + ", database is " + tabObj.getDbName());
                        }
                    }
                } else if (hiveObject.getObjectType() == HiveObjectType.COLUMN) {
                    Table tabObj = this.getTable(catName, hiveObject.getDbName(), hiveObject.getObjectName(), null);
                    String partName = null;
                    if (hiveObject.getPartValues() != null) {
                        partName = Warehouse.makePartName(tabObj.getPartitionKeys(), hiveObject.getPartValues());
                    }
                    if (partName != null) {
                        List<MPartitionColumnPrivilege> mSecCol = listPrincipalMPartitionColumnGrants(userName, principalType, catName, hiveObject.getDbName(), hiveObject.getObjectName(), partName, hiveObject.getColumnName());
                        boolean found = false;
                        for (String privilege : privs) {
                            for (MPartitionColumnPrivilege col : mSecCol) {
                                String colPriv = col.getPrivilege();
                                if (colPriv.equalsIgnoreCase(privilege)) {
                                    found = true;
                                    if (grantOption) {
                                        if (col.getGrantOption()) {
                                            col.setGrantOption(false);
                                        } else {
                                            throw new MetaException("User " + userName + " does not have grant option with privilege " + privilege);
                                        }
                                    }
                                    persistentObjs.add(col);
                                    break;
                                }
                            }
                            if (!found) {
                                throw new InvalidObjectException("No grant (" + privilege + ") found " + " on table " + tabObj.getTableName() + ", partition is " + partName + ", column name = " + hiveObject.getColumnName() + ", database is " + tabObj.getDbName());
                            }
                        }
                    } else {
                        List<MTableColumnPrivilege> mSecCol = listPrincipalMTableColumnGrants(userName, principalType, catName, hiveObject.getDbName(), hiveObject.getObjectName(), hiveObject.getColumnName());
                        boolean found = false;
                        for (String privilege : privs) {
                            for (MTableColumnPrivilege col : mSecCol) {
                                String colPriv = col.getPrivilege();
                                if (colPriv.equalsIgnoreCase(privilege)) {
                                    found = true;
                                    if (grantOption) {
                                        if (col.getGrantOption()) {
                                            col.setGrantOption(false);
                                        } else {
                                            throw new MetaException("User " + userName + " does not have grant option with privilege " + privilege);
                                        }
                                    }
                                    persistentObjs.add(col);
                                    break;
                                }
                            }
                            if (!found) {
                                throw new InvalidObjectException("No grant (" + privilege + ") found " + " on table " + tabObj.getTableName() + ", column name = " + hiveObject.getColumnName() + ", database is " + tabObj.getDbName());
                            }
                        }
                    }
                }
            }
        }
        if (CollectionUtils.isNotEmpty(persistentObjs)) {
            if (grantOption) {
            // If grant option specified, only update the privilege, don't remove it.
            // Grant option has already been removed from the privileges in the section above
            } else {
                pm.deletePersistentAll(persistentObjs);
            }
        }
        committed = commitTransaction();
    } finally {
        if (!committed) {
            rollbackTransaction();
        }
    }
    return committed;
}
Also used : MDataConnector(org.apache.hadoop.hive.metastore.model.MDataConnector) ArrayList(java.util.ArrayList) MPartitionColumnPrivilege(org.apache.hadoop.hive.metastore.model.MPartitionColumnPrivilege) MDCPrivilege(org.apache.hadoop.hive.metastore.model.MDCPrivilege) InvalidObjectException(org.apache.hadoop.hive.metastore.api.InvalidObjectException) ValidWriteIdList(org.apache.hadoop.hive.common.ValidWriteIdList) ReplicationMetricList(org.apache.hadoop.hive.metastore.api.ReplicationMetricList) LinkedList(java.util.LinkedList) MStringList(org.apache.hadoop.hive.metastore.model.MStringList) ArrayList(java.util.ArrayList) ValidReaderWriteIdList(org.apache.hadoop.hive.common.ValidReaderWriteIdList) List(java.util.List) MTableColumnPrivilege(org.apache.hadoop.hive.metastore.model.MTableColumnPrivilege) MetaException(org.apache.hadoop.hive.metastore.api.MetaException) MVersionTable(org.apache.hadoop.hive.metastore.model.MVersionTable) SourceTable(org.apache.hadoop.hive.metastore.api.SourceTable) Table(org.apache.hadoop.hive.metastore.api.Table) MTable(org.apache.hadoop.hive.metastore.model.MTable) HiveObjectRef(org.apache.hadoop.hive.metastore.api.HiveObjectRef) MDBPrivilege(org.apache.hadoop.hive.metastore.model.MDBPrivilege) MGlobalPrivilege(org.apache.hadoop.hive.metastore.model.MGlobalPrivilege) MDatabase(org.apache.hadoop.hive.metastore.model.MDatabase) HiveObjectPrivilege(org.apache.hadoop.hive.metastore.api.HiveObjectPrivilege) MPartitionPrivilege(org.apache.hadoop.hive.metastore.model.MPartitionPrivilege) PrincipalType(org.apache.hadoop.hive.metastore.api.PrincipalType) MTablePrivilege(org.apache.hadoop.hive.metastore.model.MTablePrivilege)

Example 8 with MTableColumnPrivilege

use of org.apache.hadoop.hive.metastore.model.MTableColumnPrivilege in project hive by apache.

the class ObjectStore method addPartition.

@Override
public boolean addPartition(Partition part) throws InvalidObjectException, MetaException {
    boolean success = false;
    boolean commited = false;
    try {
        openTransaction();
        String catName = part.isSetCatName() ? part.getCatName() : getDefaultCatalog(conf);
        MTable table = this.getMTable(catName, part.getDbName(), part.getTableName());
        List<MTablePrivilege> tabGrants = null;
        List<MTableColumnPrivilege> tabColumnGrants = null;
        if ("TRUE".equalsIgnoreCase(table.getParameters().get("PARTITION_LEVEL_PRIVILEGE"))) {
            tabGrants = this.listAllTableGrants(catName, part.getDbName(), part.getTableName());
            tabColumnGrants = this.listTableAllColumnGrants(catName, part.getDbName(), part.getTableName());
        }
        MPartition mpart = convertToMPart(part, table, true);
        pm.makePersistent(mpart);
        int now = (int) (System.currentTimeMillis() / 1000);
        List<Object> toPersist = new ArrayList<>();
        if (tabGrants != null) {
            for (MTablePrivilege tab : tabGrants) {
                MPartitionPrivilege partGrant = new MPartitionPrivilege(tab.getPrincipalName(), tab.getPrincipalType(), mpart, tab.getPrivilege(), now, tab.getGrantor(), tab.getGrantorType(), tab.getGrantOption(), tab.getAuthorizer());
                toPersist.add(partGrant);
            }
        }
        if (tabColumnGrants != null) {
            for (MTableColumnPrivilege col : tabColumnGrants) {
                MPartitionColumnPrivilege partColumn = new MPartitionColumnPrivilege(col.getPrincipalName(), col.getPrincipalType(), mpart, col.getColumnName(), col.getPrivilege(), now, col.getGrantor(), col.getGrantorType(), col.getGrantOption(), col.getAuthorizer());
                toPersist.add(partColumn);
            }
            if (CollectionUtils.isNotEmpty(toPersist)) {
                pm.makePersistentAll(toPersist);
            }
        }
        commited = commitTransaction();
        success = true;
    } finally {
        if (!commited) {
            rollbackTransaction();
        }
    }
    return success;
}
Also used : ArrayList(java.util.ArrayList) MPartitionColumnPrivilege(org.apache.hadoop.hive.metastore.model.MPartitionColumnPrivilege) MConstraint(org.apache.hadoop.hive.metastore.model.MConstraint) SQLUniqueConstraint(org.apache.hadoop.hive.metastore.api.SQLUniqueConstraint) SQLCheckConstraint(org.apache.hadoop.hive.metastore.api.SQLCheckConstraint) SQLDefaultConstraint(org.apache.hadoop.hive.metastore.api.SQLDefaultConstraint) SQLNotNullConstraint(org.apache.hadoop.hive.metastore.api.SQLNotNullConstraint) MTable(org.apache.hadoop.hive.metastore.model.MTable) MPartitionPrivilege(org.apache.hadoop.hive.metastore.model.MPartitionPrivilege) MTablePrivilege(org.apache.hadoop.hive.metastore.model.MTablePrivilege) MTableColumnPrivilege(org.apache.hadoop.hive.metastore.model.MTableColumnPrivilege) MPartition(org.apache.hadoop.hive.metastore.model.MPartition)

Example 9 with MTableColumnPrivilege

use of org.apache.hadoop.hive.metastore.model.MTableColumnPrivilege in project hive by apache.

the class ObjectStore method removeRole.

@Override
public boolean removeRole(String roleName) throws MetaException, NoSuchObjectException {
    boolean success = false;
    try {
        openTransaction();
        MRole mRol = getMRole(roleName);
        pm.retrieve(mRol);
        if (mRol != null) {
            // first remove all the membership, the membership that this role has
            // been granted
            List<MRoleMap> roleMap = listMRoleMembers(mRol.getRoleName());
            if (CollectionUtils.isNotEmpty(roleMap)) {
                pm.deletePersistentAll(roleMap);
            }
            List<MRoleMap> roleMember = listMSecurityPrincipalMembershipRole(mRol.getRoleName(), PrincipalType.ROLE);
            if (CollectionUtils.isNotEmpty(roleMember)) {
                pm.deletePersistentAll(roleMember);
            }
            // then remove all the grants
            List<MGlobalPrivilege> userGrants = listPrincipalMGlobalGrants(mRol.getRoleName(), PrincipalType.ROLE);
            if (CollectionUtils.isNotEmpty(userGrants)) {
                pm.deletePersistentAll(userGrants);
            }
            List<MDBPrivilege> dbGrants = listPrincipalAllDBGrant(mRol.getRoleName(), PrincipalType.ROLE);
            if (CollectionUtils.isNotEmpty(dbGrants)) {
                pm.deletePersistentAll(dbGrants);
            }
            List<MDCPrivilege> dcGrants = listPrincipalAllDCGrant(mRol.getRoleName(), PrincipalType.ROLE);
            if (CollectionUtils.isNotEmpty(dcGrants)) {
                pm.deletePersistentAll(dcGrants);
            }
            List<MTablePrivilege> tabPartGrants = listPrincipalAllTableGrants(mRol.getRoleName(), PrincipalType.ROLE);
            if (CollectionUtils.isNotEmpty(tabPartGrants)) {
                pm.deletePersistentAll(tabPartGrants);
            }
            List<MPartitionPrivilege> partGrants = listPrincipalAllPartitionGrants(mRol.getRoleName(), PrincipalType.ROLE);
            if (CollectionUtils.isNotEmpty(partGrants)) {
                pm.deletePersistentAll(partGrants);
            }
            List<MTableColumnPrivilege> tblColumnGrants = listPrincipalAllTableColumnGrants(mRol.getRoleName(), PrincipalType.ROLE);
            if (CollectionUtils.isNotEmpty(tblColumnGrants)) {
                pm.deletePersistentAll(tblColumnGrants);
            }
            List<MPartitionColumnPrivilege> partColumnGrants = listPrincipalAllPartitionColumnGrants(mRol.getRoleName(), PrincipalType.ROLE);
            if (CollectionUtils.isNotEmpty(partColumnGrants)) {
                pm.deletePersistentAll(partColumnGrants);
            }
            // finally remove the role
            pm.deletePersistent(mRol);
        }
        success = commitTransaction();
    } catch (Exception e) {
        throw new MetaException(e.getMessage());
    } finally {
        rollbackAndCleanup(success, null);
    }
    return success;
}
Also used : MRole(org.apache.hadoop.hive.metastore.model.MRole) MPartitionColumnPrivilege(org.apache.hadoop.hive.metastore.model.MPartitionColumnPrivilege) MDBPrivilege(org.apache.hadoop.hive.metastore.model.MDBPrivilege) MGlobalPrivilege(org.apache.hadoop.hive.metastore.model.MGlobalPrivilege) AlreadyExistsException(org.apache.hadoop.hive.metastore.api.AlreadyExistsException) InvalidInputException(org.apache.hadoop.hive.metastore.api.InvalidInputException) InvalidOperationException(org.apache.hadoop.hive.metastore.api.InvalidOperationException) SQLIntegrityConstraintViolationException(java.sql.SQLIntegrityConstraintViolationException) IOException(java.io.IOException) NoSuchObjectException(org.apache.hadoop.hive.metastore.api.NoSuchObjectException) MetaException(org.apache.hadoop.hive.metastore.api.MetaException) InvalidPartitionException(org.apache.hadoop.hive.metastore.api.InvalidPartitionException) UnknownPartitionException(org.apache.hadoop.hive.metastore.api.UnknownPartitionException) InvalidObjectException(org.apache.hadoop.hive.metastore.api.InvalidObjectException) JDOException(javax.jdo.JDOException) MissingTableException(org.datanucleus.store.rdbms.exceptions.MissingTableException) SQLException(java.sql.SQLException) UnknownDBException(org.apache.hadoop.hive.metastore.api.UnknownDBException) TException(org.apache.thrift.TException) JDODataStoreException(javax.jdo.JDODataStoreException) JDOObjectNotFoundException(javax.jdo.JDOObjectNotFoundException) UnknownTableException(org.apache.hadoop.hive.metastore.api.UnknownTableException) MDCPrivilege(org.apache.hadoop.hive.metastore.model.MDCPrivilege) MPartitionPrivilege(org.apache.hadoop.hive.metastore.model.MPartitionPrivilege) MRoleMap(org.apache.hadoop.hive.metastore.model.MRoleMap) MTablePrivilege(org.apache.hadoop.hive.metastore.model.MTablePrivilege) MTableColumnPrivilege(org.apache.hadoop.hive.metastore.model.MTableColumnPrivilege) MetaException(org.apache.hadoop.hive.metastore.api.MetaException)

Example 10 with MTableColumnPrivilege

use of org.apache.hadoop.hive.metastore.model.MTableColumnPrivilege in project hive by apache.

the class ObjectStore method convertTableCols.

private List<HiveObjectPrivilege> convertTableCols(List<MTableColumnPrivilege> privs) {
    List<HiveObjectPrivilege> result = new ArrayList<>();
    for (MTableColumnPrivilege priv : privs) {
        String pname = priv.getPrincipalName();
        String authorizer = priv.getAuthorizer();
        PrincipalType ptype = PrincipalType.valueOf(priv.getPrincipalType());
        MTable mtable = priv.getTable();
        MDatabase mdatabase = mtable.getDatabase();
        HiveObjectRef objectRef = new HiveObjectRef(HiveObjectType.COLUMN, mdatabase.getName(), mtable.getTableName(), null, priv.getColumnName());
        objectRef.setCatName(mdatabase.getCatalogName());
        PrivilegeGrantInfo grantor = new PrivilegeGrantInfo(priv.getPrivilege(), priv.getCreateTime(), priv.getGrantor(), PrincipalType.valueOf(priv.getGrantorType()), priv.getGrantOption());
        result.add(new HiveObjectPrivilege(objectRef, pname, ptype, grantor, authorizer));
    }
    return result;
}
Also used : MDatabase(org.apache.hadoop.hive.metastore.model.MDatabase) HiveObjectPrivilege(org.apache.hadoop.hive.metastore.api.HiveObjectPrivilege) MTable(org.apache.hadoop.hive.metastore.model.MTable) PrivilegeGrantInfo(org.apache.hadoop.hive.metastore.api.PrivilegeGrantInfo) HiveObjectRef(org.apache.hadoop.hive.metastore.api.HiveObjectRef) ArrayList(java.util.ArrayList) PrincipalType(org.apache.hadoop.hive.metastore.api.PrincipalType) MTableColumnPrivilege(org.apache.hadoop.hive.metastore.model.MTableColumnPrivilege)

Aggregations

MTableColumnPrivilege (org.apache.hadoop.hive.metastore.model.MTableColumnPrivilege)16 ArrayList (java.util.ArrayList)11 MPartitionColumnPrivilege (org.apache.hadoop.hive.metastore.model.MPartitionColumnPrivilege)8 MConstraint (org.apache.hadoop.hive.metastore.model.MConstraint)7 MPartitionPrivilege (org.apache.hadoop.hive.metastore.model.MPartitionPrivilege)7 MTable (org.apache.hadoop.hive.metastore.model.MTable)7 MTablePrivilege (org.apache.hadoop.hive.metastore.model.MTablePrivilege)7 Query (javax.jdo.Query)6 HiveObjectPrivilege (org.apache.hadoop.hive.metastore.api.HiveObjectPrivilege)6 SQLCheckConstraint (org.apache.hadoop.hive.metastore.api.SQLCheckConstraint)6 SQLDefaultConstraint (org.apache.hadoop.hive.metastore.api.SQLDefaultConstraint)6 SQLNotNullConstraint (org.apache.hadoop.hive.metastore.api.SQLNotNullConstraint)6 SQLUniqueConstraint (org.apache.hadoop.hive.metastore.api.SQLUniqueConstraint)6 ScheduledQuery (org.apache.hadoop.hive.metastore.api.ScheduledQuery)5 MScheduledQuery (org.apache.hadoop.hive.metastore.model.MScheduledQuery)5 LinkedList (java.util.LinkedList)4 List (java.util.List)4 ValidReaderWriteIdList (org.apache.hadoop.hive.common.ValidReaderWriteIdList)4 ValidWriteIdList (org.apache.hadoop.hive.common.ValidWriteIdList)4 HiveObjectRef (org.apache.hadoop.hive.metastore.api.HiveObjectRef)4