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 1DB456ECE3; Thu, 13 Jan 2022 00:30:18 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org 1DB456ECE3 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=tarantool.org; s=dev; t=1642023018; bh=alAnnc8C2P5mYsHb4N6gw3xJFaxLN+e64vm1t8vDYzw=; h=Date:To:Cc:References:In-Reply-To:Subject:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From:Reply-To:From; b=aYV3RVGSiGqWILctDnT15/rAASvQ9JZhlP0b/A93DbuNwzS4+/PLu+xm72A20KEBy e4KZ9IbC38Tv8+1oZSeo/VqMygrHuCk+VM0qnRH9Mpy/eQHz/8E3XVxLFNmZg+QLl2 pyAu6iHiIBuOmyRvq7H8Eq0TVGKs9d/ryQKhmguA= 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 7CC966ECE3 for ; Thu, 13 Jan 2022 00:30:16 +0300 (MSK) DKIM-Filter: OpenDKIM Filter v2.11.0 dev.tarantool.org 7CC966ECE3 Received: by smtpng3.m.smailru.net with esmtpa (envelope-from ) id 1n7lCB-0005WL-Jx; Thu, 13 Jan 2022 00:30:16 +0300 Message-ID: <63f0bdcc-4ab1-6fa9-411f-ddce6e0aa215@tarantool.org> Date: Wed, 12 Jan 2022 22:30:14 +0100 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:91.0) Gecko/20100101 Thunderbird/91.4.1 Content-Language: en-US To: Serge Petrenko , Cyrill Gorcunov Cc: tml References: <20211230202347.353494-1-gorcunov@gmail.com> <20211230202347.353494-3-gorcunov@gmail.com> <1641824923.419591282@f764.i.mail.ru> <77b533c1-0c2f-c11d-0aa6-4109674a7025@tarantool.org> In-Reply-To: <77b533c1-0c2f-c11d-0aa6-4109674a7025@tarantool.org> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-4EC0790: 10 X-7564579A: 78E4E2B564C1792B X-77F55803: 4F1203BC0FB41BD99D69EC10612BAE37C9D5E9231303FDC733C1DF0250EDEEDE182A05F5380850402B124D0C25288959E686ADDD99A23ECE2ED202E44AC9C6B0D9EC912FF52F1095 X-7FA49CB5: FF5795518A3D127A4AD6D5ED66289B5278DA827A17800CE76ABD3380F320B62CEA1F7E6F0F101C67BD4B6F7A4D31EC0BCC500DACC3FED6E28638F802B75D45FF8AA50765F7900637204D59D994DFFAD78638F802B75D45FF36EB9D2243A4F8B5A6FCA7DBDB1FC311F39EFFDF887939037866D6147AF826D82FB28D52C71456B3ED887B3365175D17117882F4460429724CE54428C33FAD305F5C1EE8F4F765FCF80095D1E57F4578A471835C12D1D9774AD6D5ED66289B52BA9C0B312567BB23117882F4460429728776938767073520B1593CA6EC85F86DF6B57BC7E6449061A352F6E88A58FB86F5D81C698A659EA7E827F84554CEF5019E625A9149C048EE9ECD01F8117BC8BEE2021AF6380DFAD18AA50765F790063735872C767BF85DA227C277FBC8AE2E8BCB5A162A2BD0125875ECD9A6C639B01B4E70A05D1297E1BBCB5012B2E24CD356 X-C1DE0DAB: 0D63561A33F958A5BD88176748230DFBF772AC38C1023366159A8455576CFA25D59269BC5F550898D99A6476B3ADF6B47008B74DF8BB9EF7333BD3B22AA88B938A852937E12ACA754D8E939D8DBE9AFC410CA545F18667F91A7EA1CDA0B5A7A0 X-C8649E89: 4E36BF7865823D7055A7F0CF078B5EC49A30900B95165D34CC972AA0E2E780C40D8B96011AAAAA8DA45BC52DB1AFF95FA8488C454A31C3AB88B05E4DA3F59CA41D7E09C32AA3244C788DEB26ED9AE812D0C7C64020D4A80FF26BFA4C8A6946B8FACE5A9C96DEB163 X-D57D3AED: 3ZO7eAau8CL7WIMRKs4sN3D3tLDjz0dLbV79QFUyzQ2Ujvy7cMT6pYYqY16iZVKkSc3dCLJ7zSJH7+u4VD18S7Vl4ZUrpaVfd2+vE6kuoey4m4VkSEu530nj6fImhcD4MUrOEAnl0W826KZ9Q+tr5ycPtXkTV4k65bRjmOUUP8cvGozZ33TWg5HZplvhhXbhDGzqmQDTd6OAevLeAnq3Ra9uf7zvY2zzsIhlcp/Y7m53TZgf2aB4JOg4gkr2biojEcbRopUAko3uwRRkvJiszQ== X-Mailru-Sender: 689FA8AB762F739339CABD9B3CA9A7D6A25D8B3820EE981D48B7C57F0FC040F73841015FED1DE5223CC9A89AB576DD93FB559BB5D741EB963CF37A108A312F5C27E8A8C3839CE0E25FEEDEB644C299C0ED14614B50AE0675 X-Mras: Ok Subject: Re: [Tarantool-patches] [PATCH v27 2/3] qsync: order access to the limbo terms 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! On 12.01.2022 15:01, Serge Petrenko wrote: > > > 11.01.2022 23:39, Cyrill Gorcunov пишет: >> On Mon, Jan 10, 2022 at 05:28:43PM +0300, Serge Petrenko wrote: >>>     Hi! Thanks for the patch! >>>          box_issue_promote() and box_issue_demote() need fine-grained locking >>>     anyway. >>>     Otherwise it’s possible that promote() is already issued, but not yet >>>     written to WAL, and some >>>     outdated request is applied by applier at that exact moment. >> True. And in previous series Vlad has asked to not move in code which is >> not covered by tests. So I think this is a task for the next part. Currently >> we cover only the race between appliers. > > Let's ask Vlad, then. > > I feel like we should fix this now, not waiting for a full fine-grained locking > patch. > > First of all, this is a known bug (and fine-grained locking was meant to > cover everything we don't know of, just in case). I am not sure I understand what you both are talking about here. Sergey, do you mean 'fine-grained locking' as big critical sections covering a lot of code at once or as many small critical sections? I am confused because of this sentence. "Cover everything we don't know" is rather opposite to fine-grained locking. I voted for big locks because apparently it was too hard to implement smaller more precise locks. > Besides, simply locking issue_promote/issue_demote should be > much easier than implementing the fine-grained locking patch. Yes. I remember the proposal was to lock entire promote/demote and other qsync/raft functions from beginning to end. Because it should be relatively easy. I didn't look at the code in this patch though, can't comment it.