MCPcopy
hub / github.com/CodisLabs/codis / IsCanceled

Method IsCanceled

pkg/utils/redis/sentinel.go:37–44  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

35}
36
37func (s *Sentinel) IsCanceled() bool {
38 select {
39 case <-s.Context.Done():
40 return true
41 default:
42 return false
43 }
44}
45
46func (s *Sentinel) NodeName(gid int) string {
47 return fmt.Sprintf("%s-%d", s.Product, gid)

Callers 2

rewatchSentinelsMethod · 0.80
rewatchSentinelsMethod · 0.80

Calls 1

DoneMethod · 0.80

Tested by

no test coverage detected