MCPcopy Create free account
hub / github.com/foxcpp/maddy / Push

Method Push

internal/updatepipe/pubsub_pipe.go:85–97  ·  view source on GitHub ↗
(upd mess.Update)

Source from the content-addressed store, hash-verified

83}
84
85func (p *PubSubPipe) Push(upd mess.Update) error {
86 psKey, err := p.channel(upd.Key)
87 if err != nil {
88 return err
89 }
90
91 updBlob, err := formatUpdate(p.myID(), upd)
92 if err != nil {
93 return err
94 }
95
96 return p.PubSub.Publish(psKey, updBlob)
97}
98
99func (p *PubSubPipe) Close() error {
100 return p.PubSub.Close()

Callers

nothing calls this directly

Calls 4

channelMethod · 0.95
myIDMethod · 0.95
formatUpdateFunction · 0.85
PublishMethod · 0.65

Tested by

no test coverage detected