|
|
@ -313,7 +313,7 @@ func (conR *ConsensusReactor) sendNewRoundStepMessage(peer *p2p.Peer) { |
|
|
|
} |
|
|
|
|
|
|
|
func (conR *ConsensusReactor) gossipDataRoutine(peer *p2p.Peer, ps *PeerState) { |
|
|
|
log := log.New("peer", peer.Key) |
|
|
|
log := log.New("peer", peer) |
|
|
|
|
|
|
|
OUTER_LOOP: |
|
|
|
for { |
|
|
@ -419,7 +419,7 @@ OUTER_LOOP: |
|
|
|
} |
|
|
|
|
|
|
|
func (conR *ConsensusReactor) gossipVotesRoutine(peer *p2p.Peer, ps *PeerState) { |
|
|
|
log := log.New("peer", peer.Key) |
|
|
|
log := log.New("peer", peer) |
|
|
|
|
|
|
|
// Simple hack to throttle logs upon sleep.
|
|
|
|
var sleeping = 0 |
|
|
@ -441,8 +441,8 @@ OUTER_LOOP: |
|
|
|
sleeping = 0 |
|
|
|
} |
|
|
|
|
|
|
|
log.Debug("gossipVotesRoutine", "rsHeight", rs.Height, "rsRound", rs.Round, |
|
|
|
"prsHeight", prs.Height, "prsRound", prs.Round, "prsStep", prs.Step) |
|
|
|
//log.Debug("gossipVotesRoutine", "rsHeight", rs.Height, "rsRound", rs.Round,
|
|
|
|
// "prsHeight", prs.Height, "prsRound", prs.Round, "prsStep", prs.Step)
|
|
|
|
|
|
|
|
// If height matches, then send LastCommit, Prevotes, Precommits.
|
|
|
|
if rs.Height == prs.Height { |
|
|
@ -749,7 +749,7 @@ func (ps *PeerState) SetHasVote(vote *types.Vote, index int) { |
|
|
|
} |
|
|
|
|
|
|
|
func (ps *PeerState) setHasVote(height int, round int, type_ byte, index int) { |
|
|
|
log := log.New("peer", ps.Peer.Key, "peerRound", ps.Round, "height", height, "round", round) |
|
|
|
log := log.New("peer", ps.Peer, "peerRound", ps.Round, "height", height, "round", round) |
|
|
|
if type_ != types.VoteTypePrevote && type_ != types.VoteTypePrecommit { |
|
|
|
PanicSanity("Invalid vote type") |
|
|
|
} |
|
|
|