MCPcopy Create free account
hub / github.com/dearcode/candy / notice

Method notice

notice/gate.go:41–53  ·  view source on GitHub ↗
(addr string, ids []*meta.PushID, msg *meta.PushMessage)

Source from the content-addressed store, hash-verified

39}
40
41func (g *gate) notice(addr string, ids []*meta.PushID, msg *meta.PushMessage) error {
42 c, err := g.getClient(addr)
43 if err != nil {
44 return errors.Trace(err)
45 }
46 req := &meta.GatePushRequest{ID: ids, Msg: msg}
47 resp, err := c.Push(context.Background(), req)
48 if err != nil {
49 return errors.Trace(err)
50 }
51
52 return resp.Header.Error()
53}

Callers

nothing calls this directly

Calls 3

getClientMethod · 0.95
PushMethod · 0.65
ErrorMethod · 0.45

Tested by

no test coverage detected