mirror of
https://github.com/ClusterCockpit/cc-backend
synced 2025-12-16 04:06:16 +01:00
Fix: Replace all Printf log messages with appropriate loglevels
This commit is contained in:
@@ -27,7 +27,7 @@ func RegisterLdapSyncService(ds string) {
|
||||
gocron.NewTask(
|
||||
func() {
|
||||
t := time.Now()
|
||||
cclog.Printf("ldap sync started at %s", t.Format(time.RFC3339))
|
||||
cclog.Infof("ldap sync started at %s", t.Format(time.RFC3339))
|
||||
if err := auth.LdapAuth.Sync(); err != nil {
|
||||
cclog.Errorf("ldap sync failed: %s", err.Error())
|
||||
}
|
||||
|
||||
@@ -25,8 +25,8 @@ func RegisterUpdateDurationWorker() {
|
||||
gocron.NewTask(
|
||||
func() {
|
||||
start := time.Now()
|
||||
cclog.Printf("Update duration started at %s\n", start.Format(time.RFC3339))
|
||||
cclog.Infof("Update duration started at %s", start.Format(time.RFC3339))
|
||||
jobRepo.UpdateDuration()
|
||||
cclog.Printf("Update duration is done and took %s\n", time.Since(start))
|
||||
cclog.Infof("Update duration is done and took %s", time.Since(start))
|
||||
}))
|
||||
}
|
||||
|
||||
@@ -34,7 +34,7 @@ func RegisterFootprintWorker() {
|
||||
c := 0
|
||||
ce := 0
|
||||
cl := 0
|
||||
cclog.Printf("Update Footprints started at %s\n", s.Format(time.RFC3339))
|
||||
cclog.Infof("Update Footprints started at %s", s.Format(time.RFC3339))
|
||||
|
||||
for _, cluster := range archive.Clusters {
|
||||
s_cluster := time.Now()
|
||||
@@ -136,6 +136,6 @@ func RegisterFootprintWorker() {
|
||||
}
|
||||
cclog.Debugf("Finish Cluster %s, took %s\n", cluster.Name, time.Since(s_cluster))
|
||||
}
|
||||
cclog.Printf("Updating %d (of %d; Skipped %d) Footprints is done and took %s\n", c, cl, ce, time.Since(s))
|
||||
cclog.Infof("Updating %d (of %d; Skipped %d) Footprints is done and took %s", c, cl, ce, time.Since(s))
|
||||
}))
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user