use of org.apache.hive.service.cli.operation.MetadataOperation in project hive by apache.
the class HiveSessionImpl method getTables.
@Override
public OperationHandle getTables(String catalogName, String schemaName, String tableName, List<String> tableTypes) throws HiveSQLException {
acquire(true, true);
OperationManager operationManager = getOperationManager();
MetadataOperation operation = operationManager.newGetTablesOperation(getSession(), catalogName, schemaName, tableName, tableTypes);
OperationHandle opHandle = operation.getHandle();
try {
operation.run();
addOpHandle(opHandle);
return opHandle;
} catch (HiveSQLException e) {
operationManager.closeOperation(opHandle);
throw e;
} finally {
release(true, true);
}
}
Aggregations