MCPcopy
hub / github.com/grpc/grpc-go / successfulRPC

Method successfulRPC

clientconn.go:1773–1783  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

1771}
1772
1773func (rt *retryThrottler) successfulRPC() {
1774 if rt == nil {
1775 return
1776 }
1777 rt.mu.Lock()
1778 defer rt.mu.Unlock()
1779 rt.tokens += rt.ratio
1780 if rt.tokens > rt.max {
1781 rt.tokens = rt.max
1782 }
1783}
1784
1785func (ac *addrConn) incrCallsStarted() {
1786 ac.channelz.ChannelMetrics.CallsStarted.Add(1)

Callers 1

finishMethod · 0.80

Calls 2

LockMethod · 0.45
UnlockMethod · 0.45

Tested by

no test coverage detected