Worker: clean up some logging

This commit is contained in:
Sybren A. Stüvel 2022-02-21 19:07:20 +01:00
parent b1b73de4ee
commit b986fa49d8
2 changed files with 4 additions and 5 deletions

View File

@ -87,16 +87,15 @@ func loadConfig(configWrangler FileConfigWrangler) (WorkerConfig, error) {
}
func loadCredentials(configWrangler FileConfigWrangler) (WorkerCredentials, error) {
logger := log.With().Str("filename", configFilename).Logger()
logger.Info().Msg("loading credentials")
var creds WorkerCredentials
err := configWrangler.LoadConfig(credentialsFilename, &creds)
if err != nil {
return WorkerCredentials{}, err
}
log.Info().
Str("filename", credentialsFilename).
Msg("loaded credentials")
return creds, nil
}

View File

@ -179,7 +179,7 @@ func signOn(ctx context.Context, cfg WorkerConfig, client api.ClientWithResponse
}
switch {
case resp.JSON200 != nil:
log.Info().
log.Debug().
Int("code", resp.StatusCode()).
Interface("resp", resp.JSON200).
Msg("signed on at Manager")