- Time Monotonicity: Time is monotonically increasing, i.e., given
a header H1 for height h1 and a header H2 for height
h2 = h1 + 1,H1.Time < H2.Time. - Time Validity: Given a set of Commit votes that forms the
block.LastCommitfield, a range of valid values for the Time field of the block header is defined only by
Precommit messages (from the LastCommit field) sent by correct processes, i.e., a faulty process cannot arbitrarily increase the Time value.
- median of a Commit is equal to the median of
Vote.Timefields of theVotemessages, where the value ofVote.Timeis counted number of times proportional to the process voting power. As the voting power is not uniform (one process one vote), a vote message is actually an aggregator of the same votes whose number is equal to the voting power of the process that has casted the corresponding votes message.
- we have four processes p1, p2, p3 and p4, with the following voting power distribution (p1, 23), (p2, 27), (p3, 10)
and (p4, 10). The total voting power is 70 (
N = 3f+1, whereNis the total voting power, andfis the maximum voting power of the faulty processes), so we assume that the faulty processes have at most 23 of voting power. Furthermore, we have the following vote messages in some LastCommit field (we ignore all fields except Time field):- (p1, 100), (p2, 98), (p3, 1000), (p4, 500). We assume that p3 and p4 are faulty processes. Let’s assume that the
block.LastCommitmessage contains votes of processes p2, p3 and p4. Median is then chosen the following way: the value 98 is counted 27 times, the value 1000 is counted 10 times and the value 500 is counted also 10 times. So the median value will be the value 98. No matter what set of messages with at least2f+1voting power we choose, the median value will always be between the values sent by correct processes.
- (p1, 100), (p2, 98), (p3, 1000), (p4, 500). We assume that p3 and p4 are faulty processes. Let’s assume that the
-
let rs denotes
RoundState(consensus internal state) of some process. Thenrs.ProposalBlock.Header.Time == median(rs.LastCommit) && rs.Proposal.Timestamp == rs.ProposalBlock.Header.Time. -
Furthermore, when creating the
votemessage, the following rules for determiningvote.Timefield should hold:-
if
rs.LockedBlockis defined thenvote.Time = max(rs.LockedBlock.Timestamp + time.Millisecond, time.Now()), wheretime.Now()denotes local Unix time in milliseconds -
else if
rs.Proposalis defined thenvote.Time = max(rs.Proposal.Timestamp + time.Millisecond,, time.Now()), -
otherwise,
vote.Time = time.Now()). In this case vote is fornilso it is not taken into account for the timestamp of the next block.
-
if