File tree Expand file tree Collapse file tree 1 file changed +8
-5
lines changed
orderer/consensus/etcdraft Expand file tree Collapse file tree 1 file changed +8
-5
lines changed Original file line number Diff line number Diff line change @@ -1671,15 +1671,18 @@ var _ = Describe("Chain", func() {
1671
1671
err := c1 .Configure (configEnv , 0 )
1672
1672
Expect (err ).ToNot (HaveOccurred ())
1673
1673
1674
- // every node has written config block to the OSN ledger
1675
- network . exec (
1676
- func ( c * chain ) {
1677
- Eventually ( c . support . WriteConfigBlockCallCount , LongEventualTimeout ). Should ( Equal ( 1 ))
1678
- })
1674
+ Eventually ( c1 . support . WriteConfigBlockCallCount , LongEventualTimeout ). Should ( Equal ( 1 ))
1675
+ // Defer assertions on c2&c3 after c2 being elected because we may disconnect c1 too
1676
+ // quickly, and the MsgApps it sends to c2/c3 are dropped. Therefore, this config block
1677
+ // on c2/c3 has not been committed yet. After c2 being elected, new leader will continue
1678
+ // the effort to commit config block, if it's not done yet.
1679
1679
1680
1680
// electing new leader
1681
1681
network .elect (2 )
1682
1682
1683
+ Eventually (c2 .support .WriteConfigBlockCallCount , LongEventualTimeout ).Should (Equal (1 ))
1684
+ Eventually (c3 .support .WriteConfigBlockCallCount , LongEventualTimeout ).Should (Equal (1 ))
1685
+
1683
1686
By ("submitting new transaction to follower" )
1684
1687
c2 .cutter .CutNext = true
1685
1688
err = c3 .Order (env , 0 )
You can’t perform that action at this time.
0 commit comments