chore: adjust log

This commit is contained in:
gVisor bot 2023-01-23 11:14:45 +08:00
parent 80cc0d8c10
commit a707db90f4
2 changed files with 4 additions and 4 deletions

View file

@ -57,7 +57,7 @@ func (f *Fetcher[V]) Initial() (V, error) {
f.UpdatedAt = &modTime f.UpdatedAt = &modTime
isLocal = true isLocal = true
if f.interval != 0 && modTime.Add(f.interval).Before(time.Now()) { if f.interval != 0 && modTime.Add(f.interval).Before(time.Now()) {
log.Infoln("[Provider] %s not updated for a long time, force refresh", f.Name()) log.Warnln("[Provider] %s not updated for a long time, force refresh", f.Name())
forceUpdate = true forceUpdate = true
} }
} else { } else {
@ -162,7 +162,7 @@ func (f *Fetcher[V]) pullLoop() {
case <-f.ticker.C: case <-f.ticker.C:
elm, same, err := f.Update() elm, same, err := f.Update()
if err != nil { if err != nil {
log.Warnln("[Provider] %s pull error: %s", f.Name(), err.Error()) log.Errorln("[Provider] %s pull error: %s", f.Name(), err.Error())
continue continue
} }

View file

@ -223,11 +223,11 @@ func loadProvider(pv provider.Provider) {
switch pv.Type() { switch pv.Type() {
case provider.Proxy: case provider.Proxy:
{ {
log.Warnln("initial proxy provider %s error: %v", (pv).Name(), err) log.Errorln("initial proxy provider %s error: %v", (pv).Name(), err)
} }
case provider.Rule: case provider.Rule:
{ {
log.Warnln("initial rule provider %s error: %v", (pv).Name(), err) log.Errorln("initial rule provider %s error: %v", (pv).Name(), err)
} }
} }