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 779F56EC40; Wed, 2 Jun 2021 00:34:06 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org 779F56EC40 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=tarantool.org; s=dev; t=1622583246; bh=gq/jCZcKe8TmuJYnCtDeJXvDxIIiu0PMhe06ioxR2lk=; h=To:References:Date:In-Reply-To:Subject:List-Id:List-Unsubscribe: List-Archive:List-Post:List-Help:List-Subscribe:From:Reply-To: From; b=ABagiMK3YL2PirMfoKIglSsRWQ+2HNwQY+WpCDgtCHinAzxS2U+HkHogtrYkqWLR6 aux4VEeSbKkbiAXZ/uaIL6dIGxp4Yjktbh7O6iSvCBsy2E7cRUEQ5PE/Pk5sVL/TCo cKAe442T2DTjixfq/pzNIFIAKlqeIoWXXPqoNB2g= Received: from smtpng3.m.smailru.net (smtpng3.m.smailru.net [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 BD5566EC40 for ; Wed, 2 Jun 2021 00:34:05 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org BD5566EC40 Received: by smtpng3.m.smailru.net with esmtpa (envelope-from ) id 1loC1U-0003gm-UZ; Wed, 02 Jun 2021 00:34:05 +0300 To: Serge Petrenko , tarantool-patches@dev.tarantool.org, gorcunov@gmail.com References: <6ed9245f407510ad3a149f62c960f89fa689909e.1622233728.git.v.shpilevoy@tarantool.org> <5b059031-b099-9fe4-8c4c-7b6ef780df73@tarantool.org> Message-ID: <2da9c4ac-a10c-9cbd-ec4b-ef35aecd0ea0@tarantool.org> Date: Tue, 1 Jun 2021 23:34:03 +0200 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:78.0) Gecko/20100101 Thunderbird/78.10.2 MIME-Version: 1.0 In-Reply-To: <5b059031-b099-9fe4-8c4c-7b6ef780df73@tarantool.org> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit X-7564579A: B8F34718100C35BD X-77F55803: 4F1203BC0FB41BD9D5B0DA836B685C5423CDB5763716BB867A249A0077715520182A05F538085040A322B5FC21AD85355A942FD9E28618AF448510164AEF9D50B5D909EFE6464809 X-7FA49CB5: FF5795518A3D127A4AD6D5ED66289B5278DA827A17800CE7FEAC828D2BF6EC3CEA1F7E6F0F101C67BD4B6F7A4D31EC0BCC500DACC3FED6E28638F802B75D45FF8AA50765F790063706922F90966A37BA8638F802B75D45FF36EB9D2243A4F8B5A6FCA7DBDB1FC311F39EFFDF887939037866D6147AF826D84914EE9D738E850FE4ED7EC6151FDB44117882F4460429724CE54428C33FAD305F5C1EE8F4F765FC974A882099E279BDA471835C12D1D9774AD6D5ED66289B52BA9C0B312567BB23117882F446042972877693876707352033AC447995A7AD18F04B652EEC242312D2E47CDBA5A96583BA9C0B312567BB231DD303D21008E29813377AFFFEAFD269A417C69337E82CC2E827F84554CEF50127C277FBC8AE2E8BA83251EDC214901ED5E8D9A59859A8B6B1CFA6D474D4A6A4089D37D7C0E48F6C5571747095F342E88FB05168BE4CE3AF X-B7AD71C0: AC4F5C86D027EB782CDD5689AFBDA7A2AD77751E876CB595E8F7B195E1C978315B4ABEA51B4E3F69E7218EB9B50BAE8A X-C1DE0DAB: 0D63561A33F958A5513BF2F2A9AF2F0F9BE388BDEF9A08A6FA1D44311BB6216ED59269BC5F550898D99A6476B3ADF6B47008B74DF8BB9EF7333BD3B22AA88B938A852937E12ACA75FBC5FED0552DA851410CA545F18667F91A7EA1CDA0B5A7A0 X-C8649E89: 4E36BF7865823D7055A7F0CF078B5EC49A30900B95165D34DFB7A809FB53708769500AECE26B47DE6F43A5FD142265F31CDDDFC9F086A1E5F6C3D330F92D1D711D7E09C32AA3244C67722DAEEAF69CEDBD1C5082B7B8FE7563871F383B54D9B3FACE5A9C96DEB163 X-D57D3AED: 3ZO7eAau8CL7WIMRKs4sN3D3tLDjz0dLbV79QFUyzQ2Ujvy7cMT6pYYqY16iZVKkSc3dCLJ7zSJH7+u4VD18S7Vl4ZUrpaVfd2+vE6kuoey4m4VkSEu530nj6fImhcD4MUrOEAnl0W826KZ9Q+tr5ycPtXkTV4k65bRjmOUUP8cvGozZ33TWg5HZplvhhXbhDGzqmQDTd6OAevLeAnq3Ra9uf7zvY2zzsIhlcp/Y7m53TZgf2aB4JOg4gkr2biojt1KCq4WZgK7LoJJAM+LQxQ== X-Mailru-Sender: 689FA8AB762F73936BC43F508A06382271C94A2FC86F105029653CCC6CBC57CE3841015FED1DE5223CC9A89AB576DD93FB559BB5D741EB963CF37A108A312F5C27E8A8C3839CE0E267EA787935ED9F1B X-Mras: Ok Subject: Re: [Tarantool-patches] [PATCH 1/1] replication: check rs uuid on subscribe process 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 review! >> The UUID ignorance on subscribe decode was introduced here: >> https://github.com/tarantool/tarantool/commit/7f8cbde3555084ad6c41f137aec4faba4648c705#diff-fc276b44b551b4eac3431c9433d4bc881790ddd7df76226d7579f80da7798f6e >> >> And I don't understand why. Maybe I miss something? The tests have >> passed. Sergey, do you remember why was it needed really? >> >> Replicaset UUID mismatch definitely means the node can't connect. >> It is not related to whether it is anonymous or not. Because it >> has nothing to do with _cluster. > > Hi! Thanks for the patch! > > That change was meant to help anonymous replicas fetch data from > multiple clusters. There was such an idea back then. > It never got implemented though, and I doubt it will. Wow, I am not sure how it is supposed to work at all. Starting from the problem that in different RS you have conflicting replica_id, and you won't be able to keep track of the changes properly. You simply can't pack the same replica_id from 2 different replicasets into one replica_id in your own journal. It does not matter if you are anon or not - the changes in the given replicasets are generated by non-anon nodes and their replica IDs will clash. > So the idea was that replica should check the replicaset UUID itself. > It doesn't work now obviously. And looks like it hadn't worked before > you introduced the ER_TOO_EARLY_SUBSCRIBE error. > The test for checking uuid on replica side didn't catch this problem > because the replica was already registered on master in it. > > Long story short, I'm ok with this change, but now you should remove > unnecessary replicaset uuid checks from replica side (in applier_subscribe). If it is not critical for you, I would leave as many checks as possible on both sides. It has nothing to do with perf but protects from unexpected situations like this one. Let me know if you want it deleted anyway. > And looks like replication/gh-3704-misc-replica-checks-cluster-id test is > obsolete now. Yes, looks like so. I deleted it on the branch.