You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The problem is last (N'th) argument is passed twice (as N' and N'th+2), this leads to incorrect default values handling in my case, when I add following changes, and expect 'off' as the default value for 5th argument:
diff --git a/test/replication/election_replica.lua b/test/replication/election_replica.lua
index 4848775f2..2ae29877a 100644
--- a/test/replication/election_replica.lua+++ b/test/replication/election_replica.lua@@ -6,7 +6,7 @@ local SYNCHRO_QUORUM = arg[1] and tonumber(arg[1]) or 3
local ELECTION_TIMEOUT = arg[2] and tonumber(arg[2]) or 0.1
local ELECTION_MODE = arg[3] or 'candidate'
local CONNECT_QUORUM = arg[4] and tonumber(arg[4]) or 3
-local ELECTION_FENCING_ENABLED = arg[5] and true or false+local ELECTION_FENCING_MODE = arg[5] or 'off'
local function instance_uri(instance_id)
return SOCKET_DIR..'/election_replica'..instance_id..'.sock';
@@ -25,7 +25,7 @@ box.cfg({
replication_connect_quorum = CONNECT_QUORUM,
election_mode = ELECTION_MODE,
election_timeout = ELECTION_TIMEOUT,
- election_fencing_enabled = ELECTION_FENCING_ENABLED,+ election_fencing_mode = ELECTION_FENCING_MODE,
replication_synchro_quorum = SYNCHRO_QUORUM,
replication_synchro_timeout = 0.1,
-- To reveal more election logs.
Call like test_run:cmd('start server '..leader..' with args="3 0.4 voter"') leads to 'voter' being passed as arg[5] and tarantool replica reporting:
[001] Configuration failed: Incorrect value for option 'election_fencing_mode': the value must be one of the following strings: 'off', 'soft', 'strict'
The text was updated successfully, but these errors were encountered:
Adding following line at the top of tarantool/test/replication/election_replica.lua
And running gh-5445-leader-inconsistency.test.lua
Produces following log when
test_run:create_cluster(SERVERS, "replication", {args='2 0.4'})
is called:And following, when
test_run:cmd('start server '..other..' with args="1 0.4 voter 2"')
is called:The problem is last (N'th) argument is passed twice (as N' and N'th+2), this leads to incorrect default values handling in my case, when I add following changes, and expect 'off' as the default value for 5th argument:
Call like
test_run:cmd('start server '..leader..' with args="3 0.4 voter"')
leads to 'voter' being passed as arg[5] and tarantool replica reporting:The text was updated successfully, but these errors were encountered: