- Mar 04, 2024
-
-
Ilya Verbin authored
Now the error message is allocated by `malloc' if it doesn't fit into the static buffer. Closes #4975 NO_DOC=bugfix
-
Magomed Kostoev authored
The benchmark tests the tree build, key search, insert and delete operations performance. The latter are tested both including and excluding the tree reballancing overhead. A very simple allocator had been introduced to mitigate the memory management overhead and noise. The benchmark functions are templated. This allows to test multiple tree configurations using the same benchmarking routines. The simplest tree configuration is used, though it's possible to add new configurations to the benchmark. Example on how to create a tree similar to the one used by the memtx index is shown in the appendix A. Closes #9630 NO_DOC=new benchmark NO_TEST=new benchmark NO_CHANGELOG=new benchmark APPENDIX A: Adding a new tree configuration to the benchmark. ```C /* Instantiate the tree. */ #define tree_s128_EXTENT_SIZE 16 * 1024 #define tree_s128_elem_t struct tree_s128_elem #define tree_s128_key_t struct tree_s128_key struct tree_s128_elem { void *tuple; /* Unused. */ int64_t hint; tree_s128_elem() = default; tree_s128_elem(int64_t hint) : hint(hint) {} }; struct tree_s128_key { void *key; /* Unused. */ uint32_t part_count; /* Unused. */ int64_t hint; tree_s128_key(int64_t hint) : hint(hint) {} }; #define BPS_TREE_NAME tree_s128_t #define BPS_TREE_BLOCK_SIZE 512 #define BPS_TREE_EXTENT_SIZE tree_s128_EXTENT_SIZE #define BPS_TREE_IS_IDENTICAL(a, b) ((a).hint == (b).hint) #define BPS_TREE_COMPARE(a, b, arg) ((a).hint - (b).hint) #define BPS_TREE_COMPARE_KEY(a, b, arg) ((a).hint - (b).hint) #define bps_tree_elem_t tree_s128_elem_t #define bps_tree_key_t tree_s128_key_t #define bps_tree_arg_t int #include "salad/bps_tree.h" #undef BPS_TREE_NAME #undef BPS_TREE_BLOCK_SIZE #undef BPS_TREE_EXTENT_SIZE #undef BPS_TREE_IS_IDENTICAL #undef BPS_TREE_COMPARE #undef BPS_TREE_COMPARE_KEY #undef bps_tree_elem_t #undef bps_tree_key_t #undef bps_tree_arg_t /** Add the new tree to the `generate_benchmarks` macro. */ #define generate_benchmarks(generator, func, arg) \ generator(tree_i64, func, arg); \ generator(tree_s128, func, arg) /* < The line to be added. */ /** Create the new tree class. */ CREATE_TREE_CLASS(tree_i64); CREATE_TREE_CLASS(tree_s128); /* < The line to be added. */ ```
-
- Mar 01, 2024
-
-
Alexander Turenko authored
In development of the configuration module we met several cases, when an order of appearance of some items is as important as a constant time access using a key. This commit adds a collection that serves such a need. It is to be used internally in the src/box/lua/config code. The module is inspired by Python's collections.OrderedDict. See the description in the module code for details. NO_DOC=the module is for internal use, at least for now NO_CHANGELOG=see NO_DOC
-
- Feb 29, 2024
-
-
Alexander Turenko authored
It brings newer codespell version: 2.1.0. Ubuntu Focal offers 1.16.0. Fixes tarantool/checkpatch#70 NO_DOC=CI adjustment NO_CHANGELOG=see NO_DOC NO_TEST=see NO_DOC
-
Yaroslav Lobankov authored
If we run a static build with ASAN enabled via Clang 16, the build will fail unless `libresolv` is in the white list of static dependencies. It looks like it is a peculiarity of Clang 16 and higher. Fixes #9740 NO_DOC=build NO_TEST=build NO_CHANGELOG=build
-
Igor Munkin authored
There are two reasons for this changeset: * The positive one: Tarantool supports -b and -j options to use LuaJIT modules since the commit bf8b76a4 ("lua: proxy -j and -b flags"), so the related tests from lua-Harness suite can be partially (since -O option is still not implemented in Tarantool) enabled. * The negative one: Tarantool diff-based tests for CLI interfaces are hard to maintain, if any change occurs in LuaJIT modules, since the aforementioned tests implement dumb comparison of the output, produced by the current CLI version against the expected one, managed by the .result file. Hence, to rule the tests related to the LuaJIT CLI interface in a more convenient way, the corresponding tests should be moved from the tests in the Tarantool repository to the tests in the LuaJIT repository. The recent LuaJIT bump landed to the master in the scope of commit 0dcf6759 ("luajit: bump new version") enables the nice checks implemented in the lua-Harness suite; this patch removes the barely maintainable diff-based tests from this repository. Follows up #5541 NO_DOC=test NO_CHANGELOG=test
-
- Feb 28, 2024
-
-
Sergey Kaplun authored
* cmake: introduce AddTestLib macro * test: prepare lauxilarily libs for LuaJIT-tests * test: separate LuaJIT helpers from ffi_util.inc * test: enable <ffi_arith_ptr.lua> in LuaJIT-tests * test: enable <ffi_bitfield.lua> in LuaJIT-tests * test: enable <ffi_call.lua> in LuaJIT-tests * test: enable <ffi_callback.lua> in LuaJIT-tests * test: enable <ffi_const.lua> in LuaJIT-tests * test: enable <ffi_convert.lua> in LuaJIT-tests * test: enable <ffi_enum.lua> in LuaJIT-tests * test: enable <ffi_gcstep_recursive.lua> * test: enable <ffi_jit_arith.lua> in LuaJIT-tests * test: enable <ffi_jit_call.lua> in LuaJIT-tests * test: enable <ffi_jit_conv.lua> in LuaJIT-tests * test: enable <ffi_lex_number.lua> in LuaJIT-tests * test: enable <ffi_metatype.lua> in LuaJIT-tests * test: enable <ffi_new.lua> in LuaJIT-tests * test: enable <ffi_parse_array.lua> in LuaJIT-tests * test: enable <ffi_parse_basic.lua> in LuaJIT-tests * test: enable <ffi_parse_cdef.lua> in LuaJIT-tests * test: enable <ffi_parse_struct.lua> LuaJIT test * test: enable <ffi_tabov.lua> LuaJIT test * test: enable <lightud.lua> LuaJIT test * test: enable <api_call.lua> LuaJIT test * test: enable <catch_wrap.lua> LuaJIT test * test: enable <catch_cpp.lua> LuaJIT test * test: introduce routine to build error message * test: enable CLI-related lua-Harness tests back Closes #7834 Part of #9398 Follows up #5541 NO_DOC=LuaJIT submodule bump NO_TEST=LuaJIT submodule bump NO_CHANGELOG=add new tests
-
Vladimir Davydov authored
We assume that if the new format can store tuples matching the old format, we can update the space format without calling the engine check_format callback. This is true for both memtx and vinyl but not for memcs (EE), which doesn't support extending field types (e.g. changing int16 to int32). Let's call the engine check_format callback unconditionally and let it decide whether tuple format checking can be skipped. Needed for tarantool/tarantool-ee#694 NO_DOC=refactoring NO_TEST=refactoring NO_CHANGELOG=refactoring
-
- Feb 26, 2024
-
-
Nikolay Shirokovskiy authored
In the commit 22d507d5 ("iproto: don't hang on uncancellable iproto request") we used TEST_BUILD define which is absent, we only have a CMake build option with such name. Let's add a define too. While at it let's also show this flag in the `tarantool.build` table. Follow-up #8423 @TarantoolBot document Title: new tarantool.build.test_build flag It is `true` if `TEST_BUILD` build option is set and `false` otherwise.
-
- Feb 22, 2024
-
-
Nikolay Shirokovskiy authored
We need to handle case of dropping new connection. When net_send_greeting() is executed the connection can be closed due to iproto_drop_connections() call. Note that in the test the Tarantool crashes for another reason. Due to access after sleep to the connection that is destroyed so its memory is poisoned. Yet we visit net_send_greeting() too in the test with patch so original issue is verified too. We also need to test that such a connection is closed. This will be done in EE version. Closes #9717 NO_DOC=bugfix
-
- Feb 21, 2024
-
-
Ilya Verbin authored
Suppose an error has a cause with some payload fields, for example: local e1 = box.error.new{'e1', foo = 'bar'} -- cause local e2 = box.error.new{'e2', prev = e1} -- effect Now it is possible to access cause payload fields via e2 directly: e2.foo -- 'bar' While looking for a payload field with a given name, we always stop at the topmost (closest to the effect) field. If there's a field with the same name deeper in the stack it is masked. Closes #9106 @TarantoolBot document Title: Document inheritance of error payload fields Product: Tarantool Since: 3.1 Root document: https://www.tarantool.io/en/doc/latest/reference/reference_lua/box_error/error_object/ [Link to the design document](https://www.notion.so/tarantool/Error-subsystem-improvements-90faa0a4714b4143abaf8bed2c10b2fc?pvs=4#c080fe2ac28b46c8b0eda7234a8852ce)
-
Ilya Verbin authored
With commit eb2c6a4a ("box/lua: allow to set custom error payload fields") it is possible to add a field named "raise", but it will override the `error_object:raise()' method. Forbid it. The user can still access masked payload fields through the `unpack()' method. NO_DOC=unreleased NO_CHANGELOG=unreleased
-
Nikolay Shirokovskiy authored
At last we can drop usage of pthread_cancel and associated functions. And remove related leak suppressions. Let's keep memory protection disabling under ASAN. Otherwise leak sanitizer may misbehave on Tarantool panic as below. ``` # Tracer caught signal 11: addr=0x705236d1e000 pc=0x57b7605b10d0 sp=0x705232a00ca0\ # ==1022907==LeakSanitizer has encountered a fatal error.\ # ==1022907==HINT: For debugging, try setting environment variable LSAN_OPTIONS=verbosity=1:log_threads=1\ # ==1022907==HINT: LeakSanitizer does not work under ptrace (strace, gdb, etc)", ``` Let's also add missing pipe/endpoint destroy in wal while at it. Close #8423 NO_CHANGELOG=internal NO_DOC=internal
-
Nikolay Shirokovskiy authored
In the commit d40ce0fa ("core: disable fibers creation after shutdown started") we disable creation of new fibers in the process of shutdown. This may cause subsystem shutdown hanging. The thing is we need fiber pool working during shutdown. For example vinyl engine uses it through "tx" endpoint. Fibers in the pool are finished after idle timeout. So we may have a situation when there is no idle fibers in the pool and we cannot create a new one. Part of #8423 NO_CHANGELOG=bugfix for unreleased version NO_DOC=bugfix for unreleased version
-
- Feb 20, 2024
-
-
Nikolay Shirokovskiy authored
Similar to handling of uncancellable iproto request let's also panic on uncancellable client fiber on shutdown. Now `sql-tap/in2.test` start to fail under ASAN. `metrics_collector` fiber of feedback_daemon is not cancelled in due time on shutdown. Server panics and test fails. Turned out the fiber is cancelled during metrics collection which is done under pcall. So cancelling is ignored and we start the loop again going to sleep. fiber.sleep() will detect cancel state after sleep but we panic before that moment. We tried to make fiber.sleep() cancellation point but 2 tests start to spin in busy loop (one of them is the test added in the patch). So this approach looks dangeous. Part of #8423 NO_CHANGELOG=internal NO_DOC=internal
-
Nikolay Shirokovskiy authored
Currently if there is uncancellable iproto request Tarantool shutdown will hang. Let's instead give it some time and then panic. On this way it is good to make iproto_drop_connections() fail on timeout. It is used in `box.ctl.iproto_lockdown` which is better to fail on timeout than to hang indefinitely too. In Tarantool CI which is run with TEST_BUILD set, we set the timeout to the infinity. This is on par with current fiber_shutdown() behaviour. We will not change the latter for a while because there is already several tests that count on that. Also it is currently easier to test that there is no hang than to test exit status. Part of #8423 NO_CHANGELOG=internal NO_DOC=internal
-
- Feb 19, 2024
-
-
Ilya Verbin authored
Currently, it's only possible to set an error cause with the set_prev method. This isn't very convenient, because one has to construct a new error without raising it, then set its cause, and only then raise it. To simplify this, a new argument `prev` is added to the error constructor. Closes #9103 @TarantoolBot document Title: Document `prev` argument to table constructor of `box.error.new` Product: Tarantool Since: 3.1 Root documents: https://www.tarantool.io/en/doc/latest/reference/reference_lua/box_error/new/ and https://www.tarantool.io/en/doc/latest/reference/reference_lua/box_error/error/ [Link to the design document](https://www.notion.so/tarantool/Error-subsystem-improvements-90faa0a4714b4143abaf8bed2c10b2fc?pvs=4#c72c870f24734020aae1fbf34e2b8569)
-
Timur Safin authored
Google fuzzing efforts revealed yet another bound condition we don't handle well in the `tnt_strptime` function: - for format `%m%g%W`; - and input string `07001`. We failed with assertion failure: ``` | datetime_strptime_fuzzer: ./src/lib/core/datetime.c:148: \ _Bool tm_to_datetime(struct tnt_tm *, struct datetime *): \ Assertion `mday >= 1 && mday <= 31' failed. ``` Closes #8525 NO_TEST=updated fuzzer corpus NO_CHANGELOG=internal NO_DOC=internal
-
Nikolay Shirokovskiy authored
We create a snapshot on SIGUSR1 signal in a newly spawned system fiber. It can interfere with Tarantool shutdown. In particular there is an assertion on shutdown during such a snapshot because of cord making snaphshot. Let's just trigger making snapshot in gc subsystem in it's own worker fiber. ``` #5 0x00007e7ec9a54d26 in __assert_fail ( assertion=0x63ad06748400 "pm_atomic_load(&cord_count) == 0", file=0x63ad067478b8 "./src/lib/core/fiber.c", line=2290, function=0x63ad06748968 <__PRETTY_FUNCTION__.6> "fiber_free") at assert.c:101 #6 0x000063ad061a6a91 in fiber_free () at /home/shiny/dev/tarantool/src/lib/core/fiber.c:2290 #7 0x000063ad05edc216 in tarantool_free () at /home/shiny/dev/tarantool/src/main.cc:632 #8 0x000063ad05edd144 in main (argc=1, argv=0x63ad079ca3b0) ``` Part of #8423 NO_CHANGELOG=internal NO_DOC=internal
-
- Feb 16, 2024
-
-
Mergen Imeev authored
Before this patch, it was possible that the config status could change to 'ready' even if there were pending alerts. This could happen if there were 'missed_privilege' warnings. Before this patch, warnings were cleared and then refilled if necessary. However, after clearing all these warnings, if there were no other warnings, the status was set to 'ready'. And if new warnings were added during the 'refilling' stage, the status did not change from 'ready' to 'check_warnings' or 'check_errors'. Part of #9689 NO_DOC=bugfix NO_CHANGELOG=unreleased bug
-
Ilya Verbin authored
By design, the error references its cause, see error_set_prev() in diag.c. Referencing the error from error_set_prev() in error.lua is wrong. Introduced by commit 2e3c81de ("error: use int64_t as reference counter"). Closes #9694 NO_DOC=bugfix NO_TEST=memory leak
-
Nikolay Shirokovskiy authored
`sql-tap/intpkey.test` start to flak under load after the commit fe769b0a ("vinyl: add graceful shutdown"). The issue is vy_scheduler_complete_tasks() may yield. So on shutdown `vinyl.scheduler` fiber may be cancelled during this yield and then we go to sleep waiting for new tasks forever. Now vinyl shutdown hangs. Part of #8423 NO_TEST=fix flaky test NO_CHANGELOG=fix flaky test NO_DOC=fix flaky test
-
Georgiy Lebedev authored
Currently, the error message is specified in the `reason` argument to the table constructor of `box.error.new`. This is confusing, because the message is accessed and printed by `error:unpack` as `message`. Let’s allow users to pass the error message in the `message` argument. We won’t drop the `reason` argument so as not to break potential users. Let's also allow to omit the message key by treating the first table constructor entry as an error message if present. The error message setting has the following priority: first table constructor entry > `message` > `reason`. This change is backwards-compatible and does not require a new `compat` option. Closes #9102 @TarantoolBot document Title: Document `message` argument to table constructor of `box.error.new` Product: Tarantool Since: 3.1 Root documents: https://www.tarantool.io/en/doc/latest/reference/reference_lua/box_error/new/ and https://www.tarantool.io/en/doc/latest/reference/reference_lua/box_error/error [Link to the design document](https://www.notion.so/tarantool/Error-subsystem-improvements-90faa0a4714b4143abaf8bed2c10b2fc?pvs=4#c984e766372743c99a4a7be79a5783f6)
-
Maxim Kokryashkin authored
In commit 3daf2399 ("ci: fix step parameters for reusable runs") the integration workflow was made reusable, but concurrency group pattern modification that was done for other workflows made reusable in the same patch was forgotten. This patch fixes the mentioned issue. NO_DOC=CI NO_TEST=CI NO_CHANGELOG=CI
-
Astronomax authored
Prior to this patch, the raft leader continued to send heartbeats even if it can't write anything, so it is seen by others as alive. As a result, once the leader encounters a disk error, it can't write anything, but the elections do not start. Now the leader resigns on the first encounter with `ER_WAL_IO` write error. Closes #9399 @TarantoolBot document Title: raft: leader resigns on the first encounter with `ER_WAL_IO` * Now the leader resigns on the first encounter with `ER_WAL_IO` write error (the leader broadcasts this).
-
Astronomax authored
Before this patch, it was possible to go into an infinite loop using `box.watch()`. Also, the tarantool got stuck in a loop when trying to call `box_register_watcher` during initialization in `box_init`. Fix it. Closes #9632 NO_DOC=bugfix
-
Ilya Verbin authored
See the docbot request for details. Closes #9104 @TarantoolBot document Title: Document custom error payload fields Product: Tarantool Since: 3.1 Root documents: https://www.tarantool.io/en/doc/latest/reference/reference_lua/box_error/new/ and https://www.tarantool.io/en/doc/latest/reference/reference_lua/box_error/error/ Since Tarantool 3.1 it is possible to add a custom payload to the error on error construction. The payload is passed as key-value pairs, where `key` is a string, and `value` is any Lua object. The key name can be arbitrary except it should not be the same as any of the built-in error field name: reason, code, type, base_type, custom_type, errno, message, prev, trace. NO_WRAP Replace: box.error.new({ reason = string[, code = number, type = string] }]) with: box.error.new({ reason = string[, code = number, type = string, key1 = value1, ...] }]) Replace: box.error({ reason = string[, code = number, type = string] }]) with: box.error({ reason = string[, code = number, type = string, key1 = value1, ...] }]) NO_WRAP
-
Nikolay Shirokovskiy authored
Fix test_shutdown_during_memtx_snapshot which fail from time to time in CI on macOS x86_64 due to hitting fiber slice limit. The issue is we insert 10k tuples in a row. Part of #8423 NO_CHANGELOG=test fix NO_DOC=test fix
-
Nikolay Shirokovskiy authored
So that graceful shutdown during heavy secondary index build is possible. Part of #8423 NO_CHANGELOG=internal NO_DOC=internal
-
Nikolay Shirokovskiy authored
Let's stop all vinyl internal fibers and threads. In case of scheduler it looks like we revert the commit e463128e ("vinyl: cancel reader and writer threads on shutdown") so we can again have delay on shutdown in 'vinyl/replica_quota.test'. I guess we should not. At the time of the commit deferring deletes was the default behavior and there is a secondary index in the test space. The deferred deletes involve TX thread communication and at moment of stopping scheduler worker threads the TX event loop was not running. This could result in worker threads hanging on stop. In this patch we stop worker threads in shutdown phase while TX event loop is active. We delete part of the test for #3412 as now we finish fibers that may use the latch. Also we restore destroying the latch. Part of #8423 NO_CHANGELOG=internal NO_DOC=internal
-
Nikolay Shirokovskiy authored
engine_shutdown() is called on free step so let's name it accordingly as other subsystems freeing functions. Also let's introduce engine_shutdown() again which will be used during Tarantool shutdown. Part of #8423 NO_TEST=refactoring/stubbing NO_CHANGELOG=refactoring/stubbing NO_DOC=refactoring/stubbing
-
Yaroslav Lobankov authored
NO_DOC=ci NO_TEST=ci NO_CHANGELOG=ci
-
- Feb 15, 2024
-
-
Maksim Kokryashkin authored
This patch fixes three issues: 1. It changes the condition for workflows so they can be run not only from the Tarantool repository but from any repository in the Tarantool organization. 2. Reusable workflows substitute the `${{ github.workflow }}` context variable with the name of their top-level workflow. This behavior causes concurrency group clashes when several reusable workflows are called from a single top-level workflow. This patch adds an additional constant part to the concurrency group pattern to solve the issue. 3. The checkout actions use the reference from the repository in which the top-level workflow is located instead of the one where the reusable workflow is located. This patch solves the issue by passing the reference explicitly. NO_DOC=CI NO_TEST=CI NO_CHANGELOG=CI
-
Maksim Kokryashkin authored
Some workflows are not relevant for integration testing. This patch disables them. NO_DOC=CI NO_TEST=CI NO_CHANGELOG=CI
-
Igor Munkin authored
* test: fix initialization in lj-549-lua-load.test.c * codehealth: add `nd` to the codespell ignore list * LJ_GC64: Always snapshot functions for non-base frames. * Avoid assertion in case of stack overflow from stitched trace. * Fix recording of __concat metamethod. * Avoid out-of-range number of results when compiling select(k, ...). * Consider slots used by upvalues in use-def analysis. * Only emit proper parent references in snapshot replay. * Optimize table.new() with constant args to (sinkable) IR_TNEW. * Followup fix for embedded bytecode loader. * Fix embedded bytecode loader. * LJ_GC64: Fix HREFK optimization. * Fix unsinking of IR_FSTORE for NULL metatable. * Fix zero stripping in %g number formatting. * Follow-up fix for stack overflow handling cleanup. * Cleanup stack overflow handling. * Improve error reporting on stack overflow. * sysprof: disable runtime host symtab updates * codehealth: fix the typo * Simplify handling of instable types in TNEW/TDUP load forwarding. * Respect jit.off() on pending trace exit. * Limit exponent range in number parsing. * ARM64: Allow building with unwinding disabled. * Emit sunk IR_NEWREF only once per key on snapshot replay. Closes #7937 Closes #8140 Part of #9145 Part of #9595 NO_DOC=LuaJIT submodule bump NO_TEST=LuaJIT submodule bump
-
Mikhail Elhimov authored
Closes #8632 NO_DOC=gdb extension NO_CHANGELOG=gdb extension NO_TEST=gdb extension
-
- Feb 14, 2024
-
-
Sergey Vorontsov authored
In Linux systems based on Debian, libraries are installed in paths depending on the architecture. For example, /usr/lib/x86_64-linux-gnu/, /usr/lib/aarch64-linux-gnu/. Some packages may be installed in these paths, but Tarantool does not look for libraries installed in these paths. This patch solves the problem. Also remove redundant OS depended `if` branches. Fix #9580 NO_DOC=bugfix NO_TEST=bugfix
-
- Feb 13, 2024
-
-
Yaroslav Lobankov authored
Bump test-run to new version with the following improvements: - Bump luatest to 1.0.0-5-gf31fe34 [1] - get_iproto_port: remove duplicates [2] - requirements: bump gevent to 22.10.2 [3] - Fix decoding error when reading server's log file [4] [1] tarantool/test-run@bfcc9e8 [2] tarantool/test-run@da98d7f [3] tarantool/test-run@bc1c473 [4] tarantool/test-run@434cbec NO_DOC=test NO_TEST=test NO_CHANGELOG=test
-
Ilya Verbin authored
Switch the legacy `box.iproto.override()' interface to the newly introduced event triggers. This change is mostly not user-visible, except: - Now it can be called before `box.cfg{}'; - Now request type can be set as a string; - Some changes in error messages; - The "overriding does not support ... request type" error is logged, rather than raised; - The internal trigger is visible via the `trigger' module. If some request type is overridden by both interfaces (legacy `box.iproto.override()' and new `trigger.set()'), the order of invocation of the handlers is unspecified. Closes #8138 NO_DOC=internal
-
Ilya Verbin authored
This patch allows to override IPROTO request handlers by setting triggers on the corresponding events after the initial `box.cfg{}' call. Part of #8138 @TarantoolBot document Title: Document iproto override using event triggers Product: Tarantool Since: 3.1 Root document: New page - https://www.tarantool.io/en/doc/latest/reference/reference_lua/trigger/ Since Tarantool 3.1 there are 2 ways to override iproto request handlers: 1. Using `box.iproto.override()`, introduced in Tarantool 2.11: https://www.tarantool.io/en/doc/latest/reference/reference_lua/box_iproto/override/ 2. Using universal trigger registry: tarantool/doc#3988 To override an iproto request handler for the given request type, one can set a trigger (or multiple triggers) on the corresponding event. There are 2 types of iproto-overriding events: 1. set by request type id, e.g.: - box.iproto.override[1] - box.iproto.override[-1] 2. set by request type name (the name must be in the lowercase), e.g.: - box.iproto.override.select - box.iproto.override.unknown Override-by-id allows to set a handler for a particular request type, that is not known by the given version of Tarantool. This is not possible with override-by-name, where a type name must be known by Tarantool. Also there are a special type name "unknown" and a type id box.iproto.type.UNKNOWN (== -1) that allow to set a single handler for all unknown request types. Multiple triggers can be associated with a single event. The triggers are called in reverse order of their installation, however triggers set by id are called before triggers set by name. If a trigger returns `false`, the next trigger in the list is called, or a system handler if there are no more triggers. If a trigger returns `true`, no more triggers or system handlers are called. If some request type is overridden by both interfaces (legacy `box.iproto.override()' and new `trigger.set()'), the order of invocation of those handlers is unspecified. Co-authored-by:
Andrey Saranchin <Andrey22102001@gmail.com>
-