MCPcopy Index your code
hub / github.com/google/seesaw / addNote

Method addNote

engine/sync.go:212–223  ·  view source on GitHub ↗

addNote adds a notification to the synchronisation session. If the notes channel is full the session is marked as desynchronised and the notification is discarded.

(note *SyncNote)

Source from the content-addressed store, hash-verified

210// channel is full the session is marked as desynchronised and the notification
211// is discarded.
212func (ss *syncSession) addNote(note *SyncNote) {
213 select {
214 case ss.notes <- note:
215 default:
216 ss.Lock()
217 if !ss.desync {
218 log.Warningf("Sync session with %v is desynchronised", ss.node)
219 ss.desync = true
220 }
221 ss.Unlock()
222 }
223}
224
225// syncServer encapsulates the data for a synchronisation server.
226type syncServer struct {

Callers 2

notifyMethod · 0.80
runMethod · 0.80

Calls

no outgoing calls

Tested by

no test coverage detected