MCPcopy
hub / github.com/rclone/rclone / notifyChangeUpstream

Method notifyChangeUpstream

backend/cache/cache.go:872–880  ·  view source on GitHub ↗

notifyChangeUpstream will loop through all the upstreams and notify of the provided remote (should be only a dir)

(remote string, entryType fs.EntryType)

Source from the content-addressed store, hash-verified

870// notifyChangeUpstream will loop through all the upstreams and notify
871// of the provided remote (should be only a dir)
872func (f *Fs) notifyChangeUpstream(remote string, entryType fs.EntryType) {
873 f.parentsForgetMu.Lock()
874 defer f.parentsForgetMu.Unlock()
875 if len(f.parentsForgetFn) > 0 {
876 for _, fn := range f.parentsForgetFn {
877 fn(remote, entryType)
878 }
879 }
880}
881
882// ChangeNotify can subscribe multiple callers
883// this is coupled with the wrapped fs ChangeNotify (if it supports it)

Callers 4

httpExpireRemoteMethod · 0.95
receiveChangeNotifyMethod · 0.95
runMethod · 0.80

Calls 2

LockMethod · 0.65
UnlockMethod · 0.65

Tested by

no test coverage detected