/** * Cancel the running operation unless it is already in a terminal state * @param opHandle * @throws HiveSQLException */ public void cancelOperation(OperationHandle opHandle) throws HiveSQLException { cancelOperation(opHandle, ""); }
@Override public void cancelOperation(OperationHandle opHandle) throws HiveSQLException { acquire(true, false); try { sessionManager.getOperationManager().cancelOperation(opHandle); } finally { release(true, false); } }
private boolean cancelOperation(Operation operation, boolean isAdmin, String errMsg) throws HiveSQLException { if (isAdmin || operation.getParentSession().getUserName().equals(SessionState.get() .getAuthenticator().getUserName())) { OperationHandle handle = operation.getHandle(); operationManager.cancelOperation(handle, errMsg); return true; } else { return false; } }
/** * Cancel the running operation unless it is already in a terminal state * @param opHandle * @throws HiveSQLException */ public void cancelOperation(OperationHandle opHandle) throws HiveSQLException { cancelOperation(opHandle, ""); }
@Override public void killQuery(String queryId, String errMsg) throws HiveException { try { Operation operation = operationManager.getOperationByQueryId(queryId); if (operation == null) { LOG.info("Query not found: " + queryId); } else { OperationHandle handle = operation.getHandle(); operationManager.cancelOperation(handle, errMsg); } } catch (HiveSQLException e) { throw new HiveException(e); } } }
@Override public void cancelOperation(OperationHandle opHandle) throws HiveSQLException { acquire(true); try { sessionManager.getOperationManager().cancelOperation(opHandle); } finally { release(true); } }
@Override public void cancelOperation(OperationHandle opHandle) throws HiveSQLException { acquire(true, false); try { sessionManager.getOperationManager().cancelOperation(opHandle); } finally { release(true, false); } }
@Override public void cancelOperation(OperationHandle opHandle) throws HiveSQLException { acquire(true); try { sessionManager.getOperationManager().cancelOperation(opHandle); } finally { release(true); } }
@Override public void cancelOperation(OperationHandle opHandle) throws HiveSQLException { acquire(true); try { sessionManager.getOperationManager().cancelOperation(opHandle); } finally { release(true); } }
@Override public void cancelOperation(OperationHandle opHandle) throws HiveSQLException { acquire(true); try { sessionManager.getOperationManager().cancelOperation(opHandle); } finally { release(true); } }