]> git.proxmox.com Git - ovs.git/commit
ovsdb raft: Fix election timer parsing in snapshot RPC.
authorHan Zhou <hzhou@ovn.org>
Wed, 13 Nov 2019 17:33:59 +0000 (09:33 -0800)
committerBen Pfaff <blp@ovn.org>
Thu, 21 Nov 2019 18:51:10 +0000 (10:51 -0800)
commit9bfb280a1705b4daa51daf9c3a66f3a67a9f0f7d
tree652079a6031d73810be8aeb934bebea72176e885
parentea5c1ba0e3b899b8b6684f23a44bbfd4331815ee
ovsdb raft: Fix election timer parsing in snapshot RPC.

Commit a76ba825 took care of saving and restoring election timer in
file header snapshot, but it didn't handle the parsing of election
timer in install_snapshot_request/reply RPC, which results in problems,
e.g. when election timer change log is compacted in snapshot and then a
new node join the cluster, the new node will use the default timer
instead of the new value.  This patch fixed it by parsing election
timer in snapshot RPC.

At the same time the patch updates the test case to cover the DB compact and
join senario. The test reveals another 2 problems related to clustered DB
compact, as commented in the test case's XXX, which need to be addressed
separately.

Signed-off-by: Han Zhou <hzhou@ovn.org>
Signed-off-by: Ben Pfaff <blp@ovn.org>
ovsdb/raft-rpc.c
ovsdb/raft.c
tests/ovsdb-cluster.at