Skip to content

Commit

Permalink
agent: don't write server metadata in dev mode
Browse files Browse the repository at this point in the history
Signed-off-by: Dan Bond <danbond@protonmail.com>
  • Loading branch information
loshz committed May 16, 2023
1 parent 59db5e1 commit ccf91c7
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions agent/agent.go
Original file line number Diff line number Diff line change
Expand Up @@ -636,8 +636,10 @@ func (a *Agent) Start(ctx context.Context) error {
return err
}

// periodically write server metadata to disk.
go a.persistServerMetadata()
// Periodically write server metadata to disk.
if !consulCfg.DevMode {
go a.persistServerMetadata()
}

incomingRPCLimiter := consul.ConfiguredIncomingRPCLimiter(
&lib.StopChannelContext{StopCh: a.shutdownCh},
Expand Down

0 comments on commit ccf91c7

Please sign in to comment.