From: Alexander Turenko <alexander.turenko@tarantool.org> To: avtikhon <avtikhon@tarantool.org> Cc: avtikhon <avtikhon@gmail.com>, tarantool-patches@freelists.org Subject: [tarantool-patches] Re: [PATCH v1 5/6] Test misc tunning Date: Wed, 10 Apr 2019 15:29:02 +0300 [thread overview] Message-ID: <20190410122902.av7scascz7nxo5v3@tkn_work_nb> (raw) In-Reply-To: <2878f14ee1b654e652693fba8b57a58f674d2769.1554127720.git.avtikhon@gmail.com> I reworked the commit according to comments below. On the branch Totktonada/test-replication-fix-flaky-fails. WBR, Alexander Turenko. On Mon, Apr 01, 2019 at 05:13:34PM +0300, avtikhon wrote: > From: avtikhon <avtikhon@gmail.com> > > --- > test/replication/misc.result | 16 ++++++++-------- > test/replication/misc.test.lua | 16 ++++++++-------- > 2 files changed, 16 insertions(+), 16 deletions(-) > > diff --git a/test/replication/misc.test.lua b/test/replication/misc.test.lua > index f60eec526..d056d30a1 100644 > --- a/test/replication/misc.test.lua > +++ b/test/replication/misc.test.lua > @@ -43,27 +43,27 @@ test_run:create_cluster(SERVERS, "replication", {args="0.1"}) > test_run:wait_fullmesh(SERVERS) > test_run:cmd("switch misc1") > test_run = require('test_run').new() > -box.cfg{replication_timeout = 0.01, replication_connect_timeout=0.01} > +box.cfg{replication_timeout = 0.03, replication_connect_timeout=0.03} We can set replication_connect_timeout to 30 seconds here as in other tests. I had a question why replication_timeout is set to 0.03, while it is 0.1 in other tests. Now I understood that it increases duration of the test case about heartbeats. Such unobvious points need to be commented in a commit message. > test_run:cmd("switch misc2") > test_run = require('test_run').new() > -box.cfg{replication_timeout = 0.01, replication_connect_timeout=0.01} > +box.cfg{replication_timeout = 0.03, replication_connect_timeout=0.03} > test_run:cmd("switch misc3") > test_run = require('test_run').new() > fiber=require('fiber') > -box.cfg{replication_timeout = 0.01, replication_connect_timeout=0.01} > +box.cfg{replication_timeout = 0.03, replication_connect_timeout=0.03} > _ = box.schema.space.create('test_timeout'):create_index('pk') > test_run:cmd("setopt delimiter ';'") > function wait_follow(replicaA, replicaB) > return test_run:wait_cond(function() > return replicaA.status ~= 'follow' or replicaB.status ~= 'follow' > - end, 0.01) > + end, 0.1) I would use box.cfg.replication_timeout value here explicitly. > end ; > function test_timeout() > local replicaA = box.info.replication[1].upstream or box.info.replication[2].upstream > local replicaB = box.info.replication[3].upstream or box.info.replication[2].upstream > local follows = test_run:wait_cond(function() > return replicaA.status == 'follow' or replicaB.status == 'follow' > - end, 0.1) > + end, 1) We can just leave the timeout here to use default 60 seconds. > if not follows then error('replicas not in follow status') end > for i = 0, 99 do > box.space.test_timeout:replace({1}) > @@ -166,7 +166,7 @@ fiber.sleep(0.1) > box.schema.user.create('cluster', {password='pass'}) > box.schema.user.grant('cluster', 'replication') > > -while box.info.replication[2] == nil do fiber.sleep(0.01) end > +while box.info.replication[2] == nil do fiber.sleep(0.03) end I don't think this can change any behaviour. > vclock = test_run:get_vclock('default') > _ = test_run:wait_vclock('misc_gh3637', vclock) > > @@ -194,12 +194,12 @@ listen = box.cfg.listen > box.cfg{listen = ''} > > test_run:cmd("switch misc_gh3610") > -box.cfg{replication_connect_quorum = 0, replication_connect_timeout = 0.01} > +box.cfg{replication_connect_quorum = 0, replication_connect_timeout = 0.03} Can we use standard 30 seconds here? > box.cfg{replication = {replication, replication}} > > test_run:cmd("switch default") > box.cfg{listen = listen} > -while test_run:grep_log('misc_gh3610', 'duplicate connection') == nil do fiber.sleep(0.01) end > +while test_run:grep_log('misc_gh3610', 'duplicate connection') == nil do fiber.sleep(0.03) end I don't think this can change any behaviour. > > test_run:cmd("stop server misc_gh3610") > test_run:cmd("cleanup server misc_gh3610") > -- > 2.17.1 >
next prev parent reply other threads:[~2019-04-10 12:29 UTC|newest] Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top 2019-04-01 14:13 [tarantool-patches] [PATCH v1 1/6] Update the timeouts, set to use the default value avtikhon 2019-04-01 14:13 ` [tarantool-patches] [PATCH v1 2/6] Insert status calls inside wait_cond routines avtikhon 2019-04-10 12:26 ` [tarantool-patches] " Alexander Turenko 2019-04-01 14:13 ` [tarantool-patches] [PATCH v1 3/6] Rename replicas to the each test specified name avtikhon 2021-05-26 21:02 ` [Tarantool-patches] " Alexander Turenko via Tarantool-patches 2019-04-01 14:13 ` [tarantool-patches] [PATCH v1 4/6] Removed unused variable avtikhon 2019-04-01 14:13 ` [tarantool-patches] [PATCH v1 5/6] Test misc tunning avtikhon 2019-04-10 12:29 ` Alexander Turenko [this message] 2019-04-01 14:13 ` [tarantool-patches] [PATCH v1 6/6] Fix wait_fullmesh avtikhon 2019-04-10 12:32 ` [tarantool-patches] Re: [PATCH v1 1/6] Update the timeouts, set to use the default value Alexander Turenko
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=20190410122902.av7scascz7nxo5v3@tkn_work_nb \ --to=alexander.turenko@tarantool.org \ --cc=avtikhon@gmail.com \ --cc=avtikhon@tarantool.org \ --cc=tarantool-patches@freelists.org \ --subject='[tarantool-patches] Re: [PATCH v1 5/6] Test misc tunning' \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: link
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox