From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from smtp54.i.mail.ru (smtp54.i.mail.ru [217.69.128.34]) (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 8F0FD469710 for ; Mon, 23 Nov 2020 08:30:24 +0300 (MSK) Date: Mon, 23 Nov 2020 08:30:21 +0300 From: "Alexander V. Tikhonov" Message-ID: <20201123053021.GA45371@hpalx> References: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: Subject: Re: [Tarantool-patches] [PATCH v2 00/16] Raft module, part 2 - relocation to src/lib/raft List-Id: Tarantool development patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Vladislav Shpilevoy Cc: tarantool-patches@dev.tarantool.org Hi Vlad, thanks for the patch, as I see no new degradation found in gitlab-ci testing commit criteria pipeline [1], patch LGTM. [1] - https://gitlab.com/tarantool/tarantool/-/pipelines/219744245 On Fri, Nov 20, 2020 at 12:45:56AM +0100, Vladislav Shpilevoy wrote: > The patchset is a second part of Raft relocation to a new module for the sake of > unit testing. This part does the relocation itself. > > It entirely consists of removal of box dependencies from raft code. > > The third part will virtualize Raft event loop at compile-time, and will > introduce customizable implementations for network, disk, event loop, and time > to perform unit tests. > > Branch: http://github.com/tarantool/tarantool/tree/gerold103/gh-5303-p2-src-lib-raft > Issue: https://github.com/tarantool/tarantool/issues/5303 > > Changes in v2: > - Renames and comment fixes; > - Fixed the bug when a follower could be writable for some time. But don't know > how to test it in a sane way. Should be easy to cover in a unit test though. > The fix is done in the commits from "raft: make worker non-cancellable during > WAL write" to "move RO summary update to box-Raft". > > Vladislav Shpilevoy (16): > raft: move sources to raftlib.h/.c > raft: move box_raft_* to src/box/raft.h and .c > raft: stop using replication_disconnect_timeout() > raft: stop using replication_synchro_quorum > raft: stop using instance_id > raft: make raft_request.vclock constant > raft: stop using replicaset.vclock > raft: introduce vtab for disk and network > raft: introduce raft_msg, drop xrow dependency > raft: make worker non-cancellable during WAL write > raft: move worker fiber from Raft library to box > raft: move synchro queue clear to the worker fiber > raft: invoke update triggers within state machine > raft: move RO summary update to box-Raft > raft: introduce RaftError > raft: move algorithm code to src/lib/raft > > src/box/CMakeLists.txt | 2 +- > src/box/applier.cc | 2 +- > src/box/box.cc | 44 +- > src/box/memtx_engine.c | 4 +- > src/box/raft.c | 1200 ++++++----------------------------- > src/box/raft.h | 252 +------- > src/box/replication.cc | 3 + > src/box/xrow.c | 2 +- > src/box/xrow.h | 6 +- > src/lib/CMakeLists.txt | 1 + > src/lib/core/diag.h | 2 + > src/lib/core/exception.cc | 24 + > src/lib/core/exception.h | 7 + > src/lib/raft/CMakeLists.txt | 7 + > src/lib/raft/raft.c | 997 +++++++++++++++++++++++++++++ > src/lib/raft/raft.h | 357 +++++++++++ > 16 files changed, 1652 insertions(+), 1258 deletions(-) > create mode 100644 src/lib/raft/CMakeLists.txt > create mode 100644 src/lib/raft/raft.c > create mode 100644 src/lib/raft/raft.h > > -- > 2.24.3 (Apple Git-128) >