MCPcopy Create free account
hub / github.com/InferCore/InferCore / noteTimeoutForScaling

Method noteTimeoutForScaling

internal/server/server.go:838–850  ·  view source on GitHub ↗
(err error)

Source from the content-addressed store, hash-verified

836}
837
838func (s *Server) noteTimeoutForScaling(err error) {
839 if err == nil {
840 return
841 }
842 if errors.Is(err, context.DeadlineExceeded) {
843 s.recordTimeoutSpike()
844 return
845 }
846 var ue *upstream.Error
847 if errors.As(err, &ue) && ue.Kind == upstream.KindTimeout {
848 s.recordTimeoutSpike()
849 }
850}
851
852func (s *Server) recordTimeoutSpike() {
853 s.timeoutSpikeMu.Lock()

Callers

nothing calls this directly

Calls 1

recordTimeoutSpikeMethod · 0.95

Tested by

no test coverage detected