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 4D7946EC55; Sun, 11 Jul 2021 17:00:39 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org 4D7946EC55 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=tarantool.org; s=dev; t=1626012039; bh=ZACoic8s+DJ3anKG5nqj2omOO+G3oMtAJFjAxN+CFbE=; 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=OASHlkNHWrFyO4M9AzPJmU7aAD5YP73elPwj/GSQR9Fn8TnvXQtgYxCpv33HwXvzl oAMZXVxMtv3T4hQcO/mFFtHwzhSNC8IhRHZnNkRw0yTYagVTb6cBACwm8IOW3Fl0sU b9HPLdu7VeY0CmQrgUCtenR/V/L5vwNrERLbgwiY= Received: from smtpng2.i.mail.ru (smtpng2.i.mail.ru [94.100.179.3]) (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 B6E346EC55 for ; Sun, 11 Jul 2021 17:00:37 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org B6E346EC55 Received: by smtpng2.m.smailru.net with esmtpa (envelope-from ) id 1m2a0a-0003ZF-Sz; Sun, 11 Jul 2021 17:00:37 +0300 To: Cyrill Gorcunov , tml References: <20210710222803.253251-1-gorcunov@gmail.com> Message-ID: Date: Sun, 11 Jul 2021 16:00:35 +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: <20210710222803.253251-1-gorcunov@gmail.com> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit X-4EC0790: 10 X-7564579A: EEAE043A70213CC8 X-77F55803: 4F1203BC0FB41BD954DFF1DC42D673FBBD367E85DD81335AB0D1C33BC341B12B182A05F538085040D1CC098ED14B37284C06200FDA64A8A6B35A6141614FDE925485BF0B6DC5E796 X-7FA49CB5: FF5795518A3D127A4AD6D5ED66289B5278DA827A17800CE792C68BF9CD4C0E9EEA1F7E6F0F101C67BD4B6F7A4D31EC0BCC500DACC3FED6E28638F802B75D45FF8AA50765F7900637829D9538242026C38638F802B75D45FF36EB9D2243A4F8B5A6FCA7DBDB1FC311F39EFFDF887939037866D6147AF826D89947D9E97728F6F309C3A64F14C11ED2117882F4460429724CE54428C33FAD305F5C1EE8F4F765FC587F3D2152687E5CA471835C12D1D9774AD6D5ED66289B52BA9C0B312567BB23117882F4460429728776938767073520140C956E756FBB7ACB629EEF1311BF91D2E47CDBA5A96583BA9C0B312567BB231DD303D21008E29813377AFFFEAFD269A417C69337E82CC2E827F84554CEF50127C277FBC8AE2E8BA83251EDC214901ED5E8D9A59859A8B6AC294AFEFA671E80089D37D7C0E48F6C5571747095F342E88FB05168BE4CE3AF X-C1DE0DAB: 0D63561A33F958A5E4F1BFFB0EF20E21324F7FB7505E039F304CAA3BD2C4B3DCD59269BC5F550898D99A6476B3ADF6B47008B74DF8BB9EF7333BD3B22AA88B938A852937E12ACA753753CEE10E4ED4A7410CA545F18667F91A7EA1CDA0B5A7A0 X-C8649E89: 4E36BF7865823D7055A7F0CF078B5EC49A30900B95165D34F1ADD4D8CD3C81CE9B6491E2039A380FC7A354EC7A6A20A53637EC13BBFD94F33928AA57114A8B951D7E09C32AA3244C56C744EAAABE2429F9E5FE254CE0913D8580396430872480FACE5A9C96DEB163 X-D57D3AED: 3ZO7eAau8CL7WIMRKs4sN3D3tLDjz0dLbV79QFUyzQ2Ujvy7cMT6pYYqY16iZVKkSc3dCLJ7zSJH7+u4VD18S7Vl4ZUrpaVfd2+vE6kuoey4m4VkSEu530nj6fImhcD4MUrOEAnl0W826KZ9Q+tr5ycPtXkTV4k65bRjmOUUP8cvGozZ33TWg5HZplvhhXbhDGzqmQDTd6OAevLeAnq3Ra9uf7zvY2zzsIhlcp/Y7m53TZgf2aB4JOg4gkr2bioj/3sbGI30XhffZ8X3GEPFhA== X-Mailru-Sender: 689FA8AB762F7393C37E3C1AEC41BA5DF4314427CBDA761566ED6C45907CF58A3841015FED1DE5223CC9A89AB576DD93FB559BB5D741EB963CF37A108A312F5C27E8A8C3839CE0E267EA787935ED9F1B X-Mras: Ok Subject: Re: [Tarantool-patches] [PATCH] limbo: introduce request processing hooks 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 11.07.2021 00:28, Cyrill Gorcunov wrote: > Guys, this is an early rfc since I would like to discuss the > design first before going further. Currently we don't interrupt > incoming syncro requests which doesn't allow us to detect cluster > split-brain situation, as we were discussing verbally there are > a number of sign to detect it and we need to stop receiving data > from obsolete nodes. > > The main problem though is that such filtering of incoming packets > should happen at the moment where we still can do a step back and > inform the peer that data has been declined, but currently our > applier code process syncro requests inside WAL trigger, ie when > data is already applied or rolling back. > > Thus we need to separate "filer" and "apply" stages of processing. > What is more interesting is that we filter incomings via in memory > vclock and update them immediately. Thus the following situation > is possible -- a promote request comes in, we remember it inside > promote_term_map but then write to WAL fails and we never revert > the promote_term_map variable, thus other peer won't be able to > resend us this promote request because now we think that we've > alreday applied the promote. Well, I still don't understand what the issue is. We discussed it privately already. You simply should not apply anything until WAL write is done. And it is not happening now on the master. The terms vclock is updated only **after** WAL write. Why do you need all these new vclocks if you should not apply anything before WAL write in the first place? > write to WAL fails and we never revert > the promote_term_map variable This simply should not be possible. The term map is updated only after WAL write is done. At least this is how it works now, doesn't it? Why did you change it? (In case you did, because I am not sure, I didn't review the code throughly).