MCPcopy
hub / github.com/google/seesaw / handleNote

Method handleNote

engine/sync.go:477–497  ·  view source on GitHub ↗

handleNote dispatches a synchronisation note to the appropriate handler.

(note *SyncNote)

Source from the content-addressed store, hash-verified

475
476// handleNote dispatches a synchronisation note to the appropriate handler.
477func (sc *syncClient) handleNote(note *SyncNote) {
478 switch note.Type {
479 case SNTHeartbeat:
480 log.V(1).Infoln("Sync client received heartbeat")
481
482 case SNTDesync:
483 sc.handleDesync()
484
485 case SNTConfigUpdate:
486 sc.handleConfigUpdate(note)
487
488 case SNTHealthcheck:
489 sc.handleHealthcheck(note)
490
491 case SNTOverride:
492 sc.handleOverride(note)
493
494 default:
495 log.Errorf("Unable to handle sync notification type %s (%d)", note.Type, note.Type)
496 }
497}
498
499// handleDesync handles a desync notification.
500func (sc *syncClient) handleDesync() {

Callers

nothing calls this directly

Calls 4

handleDesyncMethod · 0.95
handleConfigUpdateMethod · 0.95
handleHealthcheckMethod · 0.95
handleOverrideMethod · 0.95

Tested by

no test coverage detected