Skip to content

Commit

Permalink
Improved logging
Browse files Browse the repository at this point in the history
  • Loading branch information
tomaszslabon committed May 6, 2024
1 parent c4b504e commit ae51571
Showing 1 changed file with 7 additions and 10 deletions.
17 changes: 7 additions & 10 deletions pkg/tbtc/heartbeat.go
Original file line number Diff line number Diff line change
Expand Up @@ -161,16 +161,13 @@ func (ha *heartbeatAction) execute() error {

// If there was an error or the number of active operators during signing
// was not enough, we must consider the heartbeat procedure as a failure.
if err != nil {
logger.Infof("error while generating heartbeat signature: [%v]", err)
} else {
logger.Infof(
"not enough active operators during signing; required [%d]: "+
"actual [%d]",
activeOperatorsCount,
heartbeatSigningMinimumActiveOperators,
)
}
ha.logger.Warnf(
"heartbeat failed; [%d/%d] operators participated; the process "+
"returned [%v] as error",
activeOperatorsCount,
heartbeatSigningMinimumActiveOperators,
err,
)

// Increment the heartbeat failure counter.
*ha.failureCounter++
Expand Down

0 comments on commit ae51571

Please sign in to comment.