Skip to content

Commit

Permalink
don't warn on per-node basis
Browse files Browse the repository at this point in the history
  • Loading branch information
iansuvak committed Feb 21, 2025
1 parent 82a0903 commit 3a9dac8
Showing 1 changed file with 11 additions and 2 deletions.
13 changes: 11 additions & 2 deletions signature-aggregator/aggregator/aggregator.go
Original file line number Diff line number Diff line change
Expand Up @@ -243,7 +243,8 @@ func (s *SignatureAggregator) CreateSignedMessage(
var signedMsg *avalancheWarp.Message
// Query the validators with retries. On each retry, query one node per unique BLS pubkey
operation := func() error {
responsesExpected := len(connectedValidators.ValidatorSet.Validators) - len(signatureMap)
numRequestsToSend := len(connectedValidators.ValidatorSet.Validators) - len(signatureMap)
responsesExpected := numRequestsToSend
log.Debug(
"Aggregator collecting signatures from peers.",
zap.String("sourceBlockchainID", unsignedMessage.SourceChainID.String()),
Expand Down Expand Up @@ -289,9 +290,10 @@ func (s *SignatureAggregator) CreateSignedMessage(
zap.String("sourceSubnetID", sourceSubnet.String()),
zap.String("signingSubnetID", signingSubnet.String()),
)

for nodeID := range vdrSet {
if !sentTo.Contains(nodeID) {
log.Warn(
log.Debug(
"Failed to make async request to node",
zap.String("nodeID", nodeID.String()),
zap.Error(err),
Expand All @@ -300,6 +302,13 @@ func (s *SignatureAggregator) CreateSignedMessage(
s.metrics.FailuresSendingToNode.Inc()
}
}
if numRequestsToSend != responsesExpected {
log.Warn(
"Failed to make async request to some nodes",
zap.Int("numFailures", numRequestsToSend-responsesExpected),
zap.Int("numSent", responsesExpected),
)
}

responseCount := 0
if responsesExpected > 0 {
Expand Down

0 comments on commit 3a9dac8

Please sign in to comment.