/** * Get all tables for the specified database. * @param dbName * @return List of all tables * @throws HiveException */ public List<Table> getAllTableObjects(String dbName) throws HiveException { return getTableObjects(dbName, ".*", null); }
/** * Get all materialized views for the specified database. * @param dbName * @return List of materialized view table objects * @throws HiveException */ public List<Table> getAllMaterializedViewObjects(String dbName) throws HiveException { return getTableObjects(dbName, ".*", TableType.MATERIALIZED_VIEW); }
/** * Get materialized views for the specified database that match the provided regex pattern. * @param dbName * @param pattern * @return List of materialized view table objects * @throws HiveException */ public List<Table> getMaterializedViewObjectsByPattern(String dbName, String pattern) throws HiveException { return getTableObjects(dbName, pattern, TableType.MATERIALIZED_VIEW); }
List<Table> materializedViewTables = getTableObjects(dbName, materializedViewNames); for (Table materializedViewTable : materializedViewTables) { final Boolean outdated = isOutdatedMaterializedView(materializedViewTable, currentTxnWriteIds,