Cancel all of our outstanding requests
356663
def _cancel_outstanding(self):
        """"""
        for d in list(self._outstanding):
            d.addErrback(lambda _: None)  # Eat any uncaught errors
            d.cancel()
824309
def remove_request(self, uuid):
        
        for key in list(self._request):
            if self._request[key] == uuid:
                del self._request[key]
654201
def cancel(self):
        
        done = self.finished.is_set()
        self.finished.set()
        return not done
458043
def AckFlowProcessingRequests(self, requests):
    """"""
    for r in requests:
      key = (r.client_id, r.flow_id)
      if key in self.flow_processing_requests:
        del self.flow_processing_requests[key]
178787
def action_cancel(self):
        """"""
        self.write({'state': 'cancelled'})
        for rec in self:
            rec.message_post(
                subtype='mt_comment',
                body=_(
                    'Change request <b>%s</b> has been cancelled by %s.'
                    ) % (rec.display_name, self.env.user.name)
                )
783076
def cancel(self, order_id):
        """"""

        response = self.request(E.cancelSslCertRequest(
            E.id(order_id)
        ))

        return int(response.data.id)
500680
def cancelAllPendingResults( self ):
        """"""
        for k in self._results.keys():
            rs = self._results[k]
            self._results[k] = [ j for j in rs if isinstance(j, dict) ]
        self._pending = dict()
177210
def cancel(self, method):
        """"""
        if method in self._scheduledMethods:
            self._scheduledMethods.remove(method)

        if not self._scheduledMethods:
            self._timer.stop()
326712
def _cancel_callback(self, request_id):
        """"""
        def callback(future):
            if future.cancelled():
                self.notify(CANCEL_METHOD, {'id': request_id})
                future.set_exception(JsonRpcRequestCancelled())
        return callback
1186171
public static void endRequest() {
        final List<RequestScopedItem> result = CACHE.get();
        if (result != null) {
            CACHE.remove();
            for (final RequestScopedItem item : result) {
                item.invalidate();
            }
        }
    }
59795
@SuppressWarnings({"WeakerAccess", "unused"}) // For library users
    public Searcher cancelPendingRequests() {
        if (pendingRequests.size() != 0) {
            for (int i = 0; i < pendingRequests.size(); i++) {
                int reqId = pendingRequests.keyAt(i);
                Request r = pendingRequests.valueAt(i);
                if (!r.isFinished() && !r.isCancelled()) {
                    cancelRequest(r, reqId);
                }
            }
        }
        return this;
    }
102554
protected function resetRequests() {
        foreach($this->options as $op=>$junk){
            if(preg_match("#FeesEstimateRequestList#",$op)){
                unset($this->options[$op]);
            }
        }
    }
1242454
public synchronized void cancelAll() {
		if (activeRequests.size() > 0) {
			List<HttpRequest> temp = new ArrayList<>(activeRequests);
			for (HttpRequest request : temp) {
				request.cancel();
			}
		}
		notifyCancelledAllRequests();
	}
530978
def cancel_all_orders(self) -> List[str]:
        """"""
        order_ids = [o.id for o in self.fetch_all_open_orders()]
        return self.cancel_orders(order_ids)
356052
function cancel() {
    timeouts.forEach(function (timeout) {
      clearTimeout(timeout);
    });
    Object.keys(callbacks).forEach(function (key) {
      callbacks[key]('cancel');
      delete callbacks[key];
    });
    timeouts = [];
  }
976206
def cancel
      # there has got to be a sexy ruby way of doing this
      crawl_statuses.each do |job|
        next unless is_job_running(job.status)
        job_id = job.uuid
        puts 'cancelling job_id: ' + job_id.to_s
        Resque::Plugins::Status::Hash.kill(job_id)
      end

      # and for good measure
      `redis-cli FLUSHALL`

      head :ok
    end
1092863
private void cancelPendingSlotRequest(PendingSlotRequest pendingSlotRequest) {
		CompletableFuture<Acknowledge> request = pendingSlotRequest.getRequestFuture();

		returnPendingTaskManagerSlotIfAssigned(pendingSlotRequest);

		if (null != request) {
			request.cancel(false);
		}
	}