MCPcopy Create free account
hub / github.com/dgraph-io/dgraph / isValid

Method isValid

graphql/admin/http.go:126–139  ·  view source on GitHub ↗
(namespace uint64)

Source from the content-addressed store, hash-verified

124}
125
126func (gs *graphqlSubscription) isValid(namespace uint64) error {
127 gs.graphqlHandler.pollerMux.RLock()
128 defer gs.graphqlHandler.pollerMux.RUnlock()
129 if err := gs.graphqlHandler.isValid(namespace); err != nil {
130 return err
131 }
132 if gs.graphqlHandler.poller == nil {
133 return errors.New("poller is nil")
134 }
135 if gs.graphqlHandler.poller[namespace] == nil {
136 return errors.New("poller not found")
137 }
138 return nil
139}
140
141func (gs *graphqlSubscription) Subscribe(
142 ctx context.Context,

Callers 1

SubscribeMethod · 0.95

Calls 3

RLockMethod · 0.80
RUnlockMethod · 0.80
isValidMethod · 0.45

Tested by

no test coverage detected