Skip to content

Commit

Permalink
fix rollcall count
Browse files Browse the repository at this point in the history
Signed-off-by: Derek Anderson <[email protected]>
  • Loading branch information
dmikey committed Feb 8, 2024
1 parent 6b6db44 commit 4dfd769
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion node/head_execute.go
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ func (n *Node) headProcessExecute(ctx context.Context, from peer.ID, payload []b
func (n *Node) headExecute(ctx context.Context, requestID string, req execute.Request, subgroup string) (codes.Code, execute.ResultMap, execute.Cluster, error) {

nodeCount := -1
if req.Config.NodeCount > 1 {
if req.Config.NodeCount >= 1 {
nodeCount = req.Config.NodeCount
}

Expand Down
2 changes: 1 addition & 1 deletion node/roll_call.go
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ rollCallResponseLoop:
case <-tctx.Done():

// -1 means we'll take any peers reporting
if (len(reportingPeers) > 1 && nodeCount == -1) {
if (len(reportingPeers) >= 1 && nodeCount == -1) {
log.Info().Msg("enough peers reported for roll call")
break rollCallResponseLoop
}
Expand Down

0 comments on commit 4dfd769

Please sign in to comment.