| 241 | } |
| 242 | |
| 243 | void ControlService::CancelQueryFInstances(const CancelQueryFInstancesRequestPB* request, |
| 244 | CancelQueryFInstancesResponsePB* response, RpcContext* rpc_context) { |
| 245 | DCHECK(request->has_query_id()); |
| 246 | const TUniqueId& query_id = ProtoToQueryId(request->query_id()); |
| 247 | VLOG_QUERY << "CancelQueryFInstances(): query_id=" << PrintId(query_id); |
| 248 | // This failpoint is to allow jitter to be injected. |
| 249 | DebugActionNoFail(FLAGS_debug_actions, "CANCEL_QUERY_FINSTANCES_DELAY"); |
| 250 | QueryState::ScopedRef qs(query_id); |
| 251 | if (qs.get() == nullptr) { |
| 252 | Status status(ErrorMsg(TErrorCode::INTERNAL_ERROR, |
| 253 | Substitute("Unknown query id: $0", PrintId(query_id)))); |
| 254 | RespondAndReleaseRpc(status, response, rpc_context); |
| 255 | return; |
| 256 | } |
| 257 | qs->Cancel(); |
| 258 | RespondAndReleaseRpc(Status::OK(), response, rpc_context); |
| 259 | } |
| 260 | |
| 261 | void ControlService::RemoteShutdown(const RemoteShutdownParamsPB* req, |
| 262 | RemoteShutdownResultPB* response, RpcContext* rpc_context) { |
nothing calls this directly
no test coverage detected