Skip to content

Commit

Permalink
Don't buffer json logs on agent startup
Browse files Browse the repository at this point in the history
There's no reason to buffer json logs on agent startup
since logs in this format already aren't reordered.
  • Loading branch information
wjordan committed May 19, 2022
1 parent 3e8f52b commit 075916a
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions command/agent/command.go
Original file line number Diff line number Diff line change
Expand Up @@ -703,6 +703,8 @@ func (c *Command) Run(args []string) int {
// Swap out UI implementation if json logging is enabled
if config.LogJson {
c.Ui = &logging.HcLogUI{Log: logger}
// Don't buffer json logs because they aren't reordered anyway.
logGate.Flush()
}

// Log config files
Expand Down

0 comments on commit 075916a

Please sign in to comment.