зеркало из https://github.com/microsoft/CCF.git
ccfraft: Use `m.prevLogTerm` in `RejectAppendEntriesRequest` when finding highest match (#6028)
This commit is contained in:
Родитель
9575d6d8cf
Коммит
5e8dfdab92
|
@ -20,7 +20,11 @@
|
|||
"key9497": "NiNrjmA9/aSj4F076mVdrA=="
|
||||
},
|
||||
"uvmEndorsements": {
|
||||
"key9553": "cbneXARxfLGcqw3cc09mYQ=="
|
||||
"did:x509:0:sha256:I__iuL25oXEVFdTP_aBLx_eT1RPHbCQ_ECBQfYZpt9s::eku:1.3.6.1.4.1.311.76.59.1.2": {
|
||||
"ContainerPlat-AMD-UVM": {
|
||||
"svn": "100"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -8,7 +8,8 @@
|
|||
"responses": {
|
||||
"200": {
|
||||
"body": {
|
||||
"digest": "1cdc59855bb6b7edee42769ca3767bc9684b7a62ffcfcb8751a75dbe71c28e49"
|
||||
"memberId": "f8ac7c60c164f7f13c04ba41645b18eabcc55a8f799c83a90d001f4e89907970",
|
||||
"stateDigest": "1cdc59855bb6b7edee42769ca3767bc9684b7a62ffcfcb8751a75dbe71c28e49"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -9,7 +9,8 @@
|
|||
"responses": {
|
||||
"200": {
|
||||
"body": {
|
||||
"digest": "1cdc59855bb6b7edee42769ca3767bc9684b7a62ffcfcb8751a75dbe71c28e49"
|
||||
"memberId": "f8ac7c60c164f7f13c04ba41645b18eabcc55a8f799c83a90d001f4e89907970",
|
||||
"stateDigest": "1cdc59855bb6b7edee42769ca3767bc9684b7a62ffcfcb8751a75dbe71c28e49"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -941,7 +941,7 @@ RejectAppendEntriesRequest(i, j, m, logOk) ==
|
|||
dest |-> j],
|
||||
m)
|
||||
\/ /\ prevTerm # 0
|
||||
/\ LET lli == FindHighestPossibleMatch(log[i], m.prevLogIndex, m.term)
|
||||
/\ LET lli == FindHighestPossibleMatch(log[i], m.prevLogIndex, m.prevLogTerm)
|
||||
IN Reply([type |-> AppendEntriesResponse,
|
||||
success |-> FALSE,
|
||||
term |-> IF lli = 0 THEN StartTerm ELSE log[i][lli].term,
|
||||
|
|
Загрузка…
Ссылка в новой задаче