MCPcopy Create free account
hub / github.com/wavetermdev/waveterm / cancelRequest

Method cancelRequest

pkg/wshutil/wshrpc.go:266–277  ·  view source on GitHub ↗
(reqId string)

Source from the content-addressed store, hash-verified

264}
265
266func (w *WshRpc) cancelRequest(reqId string) {
267 if reqId == "" {
268 return
269 }
270 w.Lock.Lock()
271 defer w.Lock.Unlock()
272 handler := w.ResponseHandlerMap[reqId]
273 if handler != nil {
274 handler.canceled.Store(true)
275 }
276
277}
278
279func (w *WshRpc) handleRequest(req *RpcMessage, ingressLinkId baseds.LinkId) {
280 pprof.Do(context.Background(), pprof.Labels("rpc", req.Command), func(pprofCtx context.Context) {

Callers 1

runServerMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected