You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// Watch watches for config changes and reloads config. This method should be called after Read() to make sure that ConfReader konws which struct to reload.
299
+
// Returns a mutex that can be used to synchronize access to the config.
300
+
// If you care about thread safety, call RLock() on the mutex while accessing the config and the RUnlock().
301
+
// This will ensure that the config is not reloaded while you are accessing it.
302
+
func (c*ConfReader) Watch() *sync.RWMutex {
303
+
ifc.configStruct==nil {
304
+
log.Fatalln("ConfReader: config struct is not set. Call Read before Watch")
0 commit comments