From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from [87.239.111.99] (localhost [127.0.0.1]) by dev.tarantool.org (Postfix) with ESMTP id 8EA1F6EC40; Sun, 4 Jul 2021 15:12:47 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org 8EA1F6EC40 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=tarantool.org; s=dev; t=1625400767; bh=NHw0fG6G+JBC7ejidkeoaDVJrqcx4qoa+OISojnvCrE=; h=To:Cc:References:Date:In-Reply-To:Subject:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From:Reply-To:From; b=u9oE/iF9yDwJtEd4opP86pwptHD6c38ypE3V34zOAmv0QLUe0vZC60f8iv1hdhWEA E/AuN6Zx6m7MM+thV4ArNCrfHNZu1OGfG1MKdxQoCulCddxKQrHh4AZVUXa9rkFc+f jMDZ79tFGxFyR29HDrGKfEY7HQaQ5NxDi7V9XJB0= Received: from smtpng3.i.mail.ru (smtpng3.i.mail.ru [94.100.177.149]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dev.tarantool.org (Postfix) with ESMTPS id F075B6EC40 for ; Sun, 4 Jul 2021 15:12:45 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org F075B6EC40 Received: by smtpng3.m.smailru.net with esmtpa (envelope-from ) id 1m00zM-000540-VU; Sun, 04 Jul 2021 15:12:45 +0300 To: Serge Petrenko , gorcunov@gmail.com Cc: tarantool-patches@dev.tarantool.org References: <099ee3af81a4d9c9b9dece44f5d75d0c4351c91c.1624918077.git.sergepetrenko@tarantool.org> Message-ID: Date: Sun, 4 Jul 2021 14:12:43 +0200 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:78.0) Gecko/20100101 Thunderbird/78.11.0 MIME-Version: 1.0 In-Reply-To: <099ee3af81a4d9c9b9dece44f5d75d0c4351c91c.1624918077.git.sergepetrenko@tarantool.org> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit X-7564579A: B8F34718100C35BD X-77F55803: 4F1203BC0FB41BD954DFF1DC42D673FB8EEAA58EF109ED2DCA3B880632F394B8182A05F5380850405F3CB995D90DA9053B18A1F501E865E7B0AA8C4F52C1D5C94BFA68063080A7A8 X-7FA49CB5: FF5795518A3D127A4AD6D5ED66289B5278DA827A17800CE70CB15FA6C489297DEA1F7E6F0F101C67BD4B6F7A4D31EC0BCC500DACC3FED6E28638F802B75D45FF8AA50765F79006378D08D652E28591A78638F802B75D45FF36EB9D2243A4F8B5A6FCA7DBDB1FC311F39EFFDF887939037866D6147AF826D802CF35991F43E46A691FC940BFFD9FA0117882F4460429724CE54428C33FAD305F5C1EE8F4F765FCAA867293B0326636D2E47CDBA5A96583BD4B6F7A4D31EC0BC014FD901B82EE079FA2833FD35BB23D27C277FBC8AE2E8B2EE5AD8F952D28FBA471835C12D1D977C4224003CC8364762BB6847A3DEAEFB0F43C7A68FF6260569E8FC8737B5C2249EC8D19AE6D49635B68655334FD4449CB9ECD01F8117BC8BEAAAE862A0553A39223F8577A6DFFEA7C837C4FEFBD186071C4224003CC83647689D4C264860C145E X-C1DE0DAB: 0D63561A33F958A5FE5B08D18528CD57299049E635C703BE9AAD104785FAD9EED59269BC5F550898D99A6476B3ADF6B47008B74DF8BB9EF7333BD3B22AA88B938A852937E12ACA753753CEE10E4ED4A7410CA545F18667F91A7EA1CDA0B5A7A0 X-C8649E89: 4E36BF7865823D7055A7F0CF078B5EC49A30900B95165D34BC3EEE75EF3BACCF91D2C2CF823F29E1F8894E7FD3F022C8BCAF054FAF7EBD6DCE3D77565ECC13A51D7E09C32AA3244C826886852296DAB103478C6E8B31B784408A6A02710B7304FACE5A9C96DEB163 X-D57D3AED: 3ZO7eAau8CL7WIMRKs4sN3D3tLDjz0dLbV79QFUyzQ2Ujvy7cMT6pYYqY16iZVKkSc3dCLJ7zSJH7+u4VD18S7Vl4ZUrpaVfd2+vE6kuoey4m4VkSEu530nj6fImhcD4MUrOEAnl0W826KZ9Q+tr5ycPtXkTV4k65bRjmOUUP8cvGozZ33TWg5HZplvhhXbhDGzqmQDTd6OAevLeAnq3Ra9uf7zvY2zzsIhlcp/Y7m53TZgf2aB4JOg4gkr2bioj5fH2RN9TpJkHAI/uy1FAmQ== X-Mailru-Sender: 689FA8AB762F7393C37E3C1AEC41BA5D886229ACBB4DC45C8635037E845390C33841015FED1DE5223CC9A89AB576DD93FB559BB5D741EB963CF37A108A312F5C27E8A8C3839CE0E267EA787935ED9F1B X-Mras: Ok Subject: Re: [Tarantool-patches] [PATCH v3 01/12] replication: always send raft state to subscribers X-BeenThere: tarantool-patches@dev.tarantool.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: Tarantool development patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , From: Vladislav Shpilevoy via Tarantool-patches Reply-To: Vladislav Shpilevoy Errors-To: tarantool-patches-bounces@dev.tarantool.org Sender: "Tarantool-patches" Hi! Thanks for the patch! On 29.06.2021 00:12, Serge Petrenko via Tarantool-patches wrote: > Tarantool used to send out raft state on subscribe only when raft was > enabled. This was a safeguard against partially-upgraded clusters, where > some nodes had no clue about Raft messages and couldn't handle them > properly. > > Actually, Raft state should be sent out always. For example, promote > will be changed to bump Raft term even when Raft is disabled, and it's > important that everyone in cluster has the same term for the sake of promote > at least. > > So, send out Raft state to every subscriber with version >= 2.6.0 > (that's when Raft was introduced). > Do the same for Raft broadcasts. They should be sent only to replicas > with version >= 2.6.0 > > Closes #5438 > --- > src/box/box.cc | 11 ++-- > src/box/relay.cc | 4 +- > test/replication/gh-5438-raft-state.result | 63 ++++++++++++++++++++ > test/replication/gh-5438-raft-state.test.lua | 28 +++++++++ I propose to rename raft -> election in the test name. To be consistent with the existing election tests. Also it simplifies running all of them by doing `python test-run.py election`.