mirror of
https://github.com/netbirdio/netbird.git
synced 2025-06-25 04:01:29 +02:00
Update the check interval for new geo db and change log level (#1908)
Update log level to trace and update the check db interval from 60s to 300s
This commit is contained in:
parent
e435e39158
commit
3598418206
@ -79,7 +79,7 @@ func NewGeolocation(dataDir string) (*Geolocation, error) {
|
|||||||
sha256sum: sha256sum,
|
sha256sum: sha256sum,
|
||||||
db: db,
|
db: db,
|
||||||
locationDB: locationDB,
|
locationDB: locationDB,
|
||||||
reloadCheckInterval: 60 * time.Second, // TODO: make configurable
|
reloadCheckInterval: 300 * time.Second, // TODO: make configurable
|
||||||
stopCh: make(chan struct{}),
|
stopCh: make(chan struct{}),
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -198,7 +198,7 @@ func (gl *Geolocation) reloader() {
|
|||||||
log.Errorf("mmdb reload failed: %s", err)
|
log.Errorf("mmdb reload failed: %s", err)
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
log.Debugf("No changes in '%s', no need to reload. Next check is in %.0f seconds.",
|
log.Tracef("No changes in '%s', no need to reload. Next check is in %.0f seconds.",
|
||||||
gl.mmdbPath, gl.reloadCheckInterval.Seconds())
|
gl.mmdbPath, gl.reloadCheckInterval.Seconds())
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -150,7 +150,7 @@ func (s *SqliteStore) reload() error {
|
|||||||
|
|
||||||
log.Infof("Successfully reloaded '%s'", s.filePath)
|
log.Infof("Successfully reloaded '%s'", s.filePath)
|
||||||
} else {
|
} else {
|
||||||
log.Debugf("No changes in '%s', no need to reload", s.filePath)
|
log.Tracef("No changes in '%s', no need to reload", s.filePath)
|
||||||
}
|
}
|
||||||
|
|
||||||
return nil
|
return nil
|
||||||
|
Loading…
x
Reference in New Issue
Block a user