Skip to content

Commit

Permalink
Merge pull request #4384 from hashicorp/b-global-log-flags
Browse files Browse the repository at this point in the history
agent: global logger should use the same flags
  • Loading branch information
schmichael authored Jun 6, 2018
2 parents 6d4321c + b20a0c4 commit 1b92555
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions command/agent/agent.go
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,9 @@ func NewAgent(config *Config, logOutput io.Writer, inmem *metrics.InmemSink) (*A
InmemSink: inmem,
}

// Global logger should match internal logger as much as possible
log.SetFlags(log.LstdFlags | log.Lmicroseconds)

if err := a.setupConsul(config.Consul); err != nil {
return nil, fmt.Errorf("Failed to initialize Consul client: %v", err)
}
Expand Down

0 comments on commit 1b92555

Please sign in to comment.