Skip to content

Commit

Permalink
Recover from broken RDS connections.
Browse files Browse the repository at this point in the history
  • Loading branch information
rgooch committed Mar 8, 2021
1 parent 492143b commit 4b355ef
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions cmd/keymasterd/storage.go
Original file line number Diff line number Diff line change
Expand Up @@ -129,6 +129,8 @@ func initDBPostgres(state *RuntimeState) (err error) {
return err
}
}
// Ensure that broken connections are replaced.
state.db.SetConnMaxLifetime(state.Config.ProfileStorage.SyncInterval >> 1)
return nil
}

Expand Down

0 comments on commit 4b355ef

Please sign in to comment.