From: Konstantin Osipov <kostja@tarantool.org> To: tarantool-patches@freelists.org Cc: vdavydov@tarantool.org, georgy@tarantool.org Subject: Re: [tarantool-patches] [PATCH] replication: fix bug with zero replication_connect_quorum Date: Fri, 6 Apr 2018 11:49:46 +0300 [thread overview] Message-ID: <20180406084946.GA4214@atlas> (raw) In-Reply-To: <20180406083945.16921-1-k.belyavskiy@tarantool.org> * Konstantin Belyavskiy <k.belyavskiy@tarantool.org> [18/04/06 11:40]: > +socket = require('socket') > +--- > +... > +s = socket.tcp_server('localhost', 3371, function() end) Is it possible to avoid using a specific port? The port may be already in use for a thousand of reasons, and this will break the test. > +++ b/test/replication/replica_params.lua > @@ -0,0 +1,21 @@ > +#!/usr/bin/env tarantool > + > +local quorum = tonumber(arg[1]) > +local n_replics = tonumber(arg[2]) > +listen = os.getenv("LISTEN") > +-- Test different replicaset configurations: > +-- First, when the only address in the replicaset is itself. > +repl = {listen} > +-- To test situation with second master unavailable, add > +-- second address (should be empty). > +if n_replics == 2 then repl = { listen, '127.0.0.1:3371' } end > + > +box.cfg({ > + listen = listen, > + replication = repl, > + memtx_memory = 107374182, Why? What's magical about this number? Could you use 100 * 1024 * 1024 instead? Then it's clear the test is not using too much memory and the exact amount is also clearly visible. > + replication_connect_quorum = quorum, > + replication_connect_timeout = 0.1, > +}) > + > +require('console').listen(os.getenv('ADMIN')) Thanks, -- Konstantin Osipov, Moscow, Russia, +7 903 626 22 32 http://tarantool.io - www.twitter.com/kostja_osipov
next prev parent reply other threads:[~2018-04-06 8:49 UTC|newest] Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top 2018-04-06 8:39 Konstantin Belyavskiy 2018-04-06 8:49 ` Konstantin Osipov [this message] 2018-04-06 13:02 ` [tarantool-patches] " Konstantin Belyavskiy 2018-04-07 14:55 ` Vladimir Davydov
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=20180406084946.GA4214@atlas \ --to=kostja@tarantool.org \ --cc=georgy@tarantool.org \ --cc=tarantool-patches@freelists.org \ --cc=vdavydov@tarantool.org \ --subject='Re: [tarantool-patches] [PATCH] replication: fix bug with zero replication_connect_quorum' \ /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