Skip to content

Commit

Permalink
Add comment for new heartbeat v1 return value (#52384)
Browse files Browse the repository at this point in the history
  • Loading branch information
espadolini authored Feb 21, 2025
1 parent 961dad0 commit 50fb278
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions lib/srv/heartbeat.go
Original file line number Diff line number Diff line change
Expand Up @@ -391,6 +391,11 @@ func (h *Heartbeat) fetch() error {
}
}

// announce may upsert a new heartbeat or issue a keepalive for an existing one,
// depending on the current time and the state of the heartbeat. The returned
// boolean flag will be true if successful communication with the control plane
// has occurred as part of the announce (i.e. if the actual communication wasn't
// skipped because of time or state).
func (h *Heartbeat) announce() (doneSomething bool, _ error) {
switch h.state {
// nothing to do in those states in terms of announce
Expand Down

0 comments on commit 50fb278

Please sign in to comment.