hare: add log for round completion
## Motivation
<!-- Please mention the issue fixed by this PR or detailed motivation -->
log eligibility count upon hare round completion
MODIFY
hare/algorithm.go
hare/algorithm.go
@@ -859,6 +859,7 @@ func (proc *consensusProcess) processNotifyMsg(ctx context.Context, msg *Msg) {
log.String("current_set", proc.value.String()),
log.Uint32("current_round", proc.getRound()),
proc.layer,
+ log.Object("notify_count", notifyCount),
log.Int("set_size", proc.value.Size()))
proc.report(completed)
numIterations.Observe(float64(proc.getRound()))

MODIFY
hare/committracker.go
hare/committracker.go
@@ -110,6 +110,8 @@ func (ct *commitTracker) HasEnoughCommits() bool {
if ci.numDishonest > 0 {
ct.logger.With().Warning("counting votes from malicious identities",
log.Object("eligibility_count", ci))
+ } else {
+ ct.logger.With().Info("commit round completed", log.Object("eligibility_count", ci))
}
}
return enough

MODIFY
hare/eligibility/oracle.go
hare/eligibility/oracle.go
@@ -515,7 +515,8 @@ func (o *Oracle) actives(ctx context.Context, targetLayer types.LayerID) (map[ty
}
if len(hareActiveSet) > 0 {
- logger.With().Debug("successfully got hare active set for layer range",
+ logger.With().Info("successfully got hare active set for layer range",
+ log.Uint32("layer_range_epoch", uint32(safeLayerStart.GetEpoch())),
log.Int("count", len(hareActiveSet)))
o.activesCache.Add(safeLayerStart.GetEpoch(), hareActiveSet)
return hareActiveSet, nil

MODIFY
hare/statustracker.go
hare/statustracker.go
@@ -96,6 +96,11 @@ func (st *statusTracker) AnalyzeStatusMessages(isValid func(m *Msg) bool) {
})
st.tally = &ci
st.analyzed = true
+ if st.tally.Meet(st.threshold) {
+ st.logger.With().Info("status round completed", log.Object("eligibility_count", st.tally))
+ } else {
+ st.logger.With().Warning("status round failed", log.Object("eligibility_count", st.tally))
+ }
}
// IsSVPReady returns true if there are enough statuses to build an SVP, false otherwise.

hare: add log for round completion (#4038)

## Motivation
<!-- Please mention the issue fixed by this PR or detailed motivation -->
log eligibility count upon hare round completion