From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from localhost (localhost [127.0.0.1]) by turing.freelists.org (Avenir Technologies Mail Multiplex) with ESMTP id 4E385295F1 for ; Tue, 28 Aug 2018 12:19:17 -0400 (EDT) Received: from turing.freelists.org ([127.0.0.1]) by localhost (turing.freelists.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id hwj5gU9R4Z3I for ; Tue, 28 Aug 2018 12:19:17 -0400 (EDT) Received: from smtp38.i.mail.ru (smtp38.i.mail.ru [94.100.177.98]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by turing.freelists.org (Avenir Technologies Mail Multiplex) with ESMTPS id A1356294C7 for ; Tue, 28 Aug 2018 12:19:16 -0400 (EDT) From: Georgy Kirichenko Subject: [tarantool-patches] [PATCH 0/2] Box control event trigger Date: Tue, 28 Aug 2018 19:19:11 +0300 Message-Id: Sender: tarantool-patches-bounce@freelists.org Errors-to: tarantool-patches-bounce@freelists.org Reply-To: tarantool-patches@freelists.org List-help: List-unsubscribe: List-software: Ecartis version 1.0.0 List-Id: tarantool-patches List-subscribe: List-owner: List-post: List-archive: To: tarantool-patches@freelists.org Cc: Georgy Kirichenko Introduce a ctl event trigger fired in cases of a bootstrap/recovery status changes, a space create/alter/drop action, an applier state change and shutdown. Trigger could be set with box.ctl_event even before the first box.cfg invocation to control recovery and bootstrap behavior. The patchset contains two patches, the first fixes a lua space cache updates, the second introduces the control trigger. Georgy Kirichenko (2): Update lua space cache just after creation On ctl event trigger src/box/CMakeLists.txt | 2 + src/box/alter.cc | 46 +++-- src/box/applier.cc | 6 + src/box/box.cc | 42 ++++ src/box/lua/init.c | 2 + src/box/lua/load_cfg.lua | 1 + test/box/ctl_event.result | 364 ++++++++++++++++++++++++++++++++++ test/box/ctl_event.test.lua | 76 +++++++ test/box/errinj.result | 61 ++++++ test/box/errinj.test.lua | 27 +++ test/box/lua/trig_master.lua | 8 + test/box/lua/trig_replica.lua | 46 +++++ test/box/misc.result | 73 +++++++ test/box/misc.test.lua | 34 ++++ 14 files changed, 769 insertions(+), 19 deletions(-) create mode 100644 test/box/ctl_event.result create mode 100644 test/box/ctl_event.test.lua create mode 100644 test/box/lua/trig_master.lua create mode 100644 test/box/lua/trig_replica.lua -- 2.18.0 https://github.com/tarantool/tarantool/issues/3159 https://github.com/tarantool/tarantool/tree/g.kirichenko/gh-3159-on-ctl-event-trigger