- Dec 14, 2021
-
-
Vladimir Davydov authored
Use git from CMAKE_SOURCE_DIR instead of PROJECT_SOURCE_DIR so that if Tarantool is built as a sub-project, we will use the version of the main project.
-
Vladimir Davydov authored
To build audit log as a part of the box library, set the following cmake variables: - ENABLE_AUDIT_LOG: ON - AUDIT_LOG_SOURCES: audit log source files - EXTRA_BOX_INCLUDE_DIRS: header files needed for compilation and add "audit_impl.h" to EXTRA_BOX_INCLUDE_DIRS - then it will be included by "audit.h". If ENABLE_AUDIT_LOG is unset, then a stub implementation is built, which spits a warning to the log on an attempt to configure audit log.
-
Vladimir Davydov authored
Needed for the tests to pass with enabled audit log.
-
- Dec 13, 2021
-
-
Aleksandr Lyapunov authored
Now there's a lot of load_*/store_* functions that are designed for unaligned access to values in data stream. Unfortunately they are written in a way that makes new compilers to warn about outside bounds. Rewrite it in the most safe, cross-platform and efficient way - using memcpy. Note that memcpy with compile-time-defined size is recognized by the magority of compilers and they make the most efficient operation. Closes #6703
-
Vladimir Davydov authored
If the tarantool repository is used as a submodule named <foobar> in another repository, then the statically built binary will be placed in <binary_dir>/<foobar>/src/tarantool not in <binary_dir>/src/tarantool where static-build/CMakeLists.txt currently tries to look it up in order to run `ctest` and so we can't use static-build/CMakeLists.txt as is. Let's instead use <install_dir>/bin/tarantool This way `ctest` will work for static-build in both open-source and EE repository without requiring any modifications.
-
Alexander Turenko authored
We anyway run all tests on graviton machines in centos_{7,8}_aarch64 and fedora_{33,34}_aarch64 jobs.
-
Alexander Turenko authored
Regarding debug_aarch64: we had old git on odroid machines (see PR #6180), but now we use graviton ones and, it seems, it becomes irrelevant. Regarding memtx_allocator_based_on_malloc: it seems, checkout@v1 here is due to usage of Debian Stretch (with git 2.11) in docker, as in older release workflow. Updated it in the spirit of PR #5949. Left actions/checkout@v1 in containers jobs (coverity and jepsen*): it should be revisited separately. Left actions/checkout@v1 in perf_* jobs: they run on special machines and I don't want to dig inside this part of the infrastructure ATM.
-
Alexander Turenko authored
AFAIK we anyway run self-hosted runners from root due to all those problems like [1]. No reason to include the hack into every workflow file. If we'll going to start runners from a non-root user, it is better to pass `--user $PROPER_UID` to all docker jobs instead, see [2]: at least it does not require to place a boilerplate into all workflow files. Didn't touch perf_* jobs: don't want to dig inside this part of the infrastructure ATM. It reverts PR #5953. [1]: https://github.com/actions/checkout/issues/211 [2]: https://github.com/actions/runner/issues/691
-
Alexander Turenko authored
AFAIU it only has meaning for jobs constructed with matrix expansion. See the documentation: [1]. It is relevant to [2] as well, but already fixed on nektos/act side. [1]: https://docs.github.com/en/actions/learn-github-actions/workflow-syntax-for-github-actions#jobsjob_idstrategyfail-fast [2]: https://github.com/tarantool/tarantool-qa/issues/118
-
Timur Safin authored
Workaround for #6599 where we may randomly fail on AWS Graviton machines, while it's working properly when jit disabled. Follow-up to #5941 Relates to #6599
-
VitaliyaIoffe authored
There was a build problem with CMAKE_BUILD_TYPE=Debug build on ARM64. It was fixed in 224cb68c (build: fix build on Linux ARM64 with CMAKE_BUILD_TYPE=Debug), before this fix '-DCMAKE_C_FLAGS="-Wno-type-limits "' was used to avoid the issue, implemented by 72c77166 (github-ci: add GitHub Actions workflow for Odroid). Follow-up #6143
-
Andrey Kulikov authored
tarantool debian package MUST NOT depends on binutils package. This is due to the fact that binutils include linker and assembler, what in most cases forbidden on production servers. This dependency is a residual from times, when tarantool did use libbfd for stack unwinding. Now it simply does not required at all. Fixes #6699
-
mechanik20051988 authored
Previously, for "listen" and "replication" options URI can be passed as a number, as a string value or as a table, which contains numbers and strings, no special properties for URIs was available. Now user can pass URIs in different ways, same as in tarantool "uri" library: as before, as a table which contains URI and it's parameters in "param" table, as a table which contains URI strings and URI tables. Same as in "uri" library, which internally used to parse new "listen" and "replication" there are different ways to specify properties for URI: in a string which contains URI, after '?' delimiter, in a table which contains URI in "params" table, in "default_params" table if it is default parameters for all URIs. Closes #5928 @TarantoolBot document Title: implement ability to pass several URIs in different ways Now there are several ways to pass multiple URIs for box.cfg.listen and box.cfg.replication: ```lua -- As a string with one or several URIs separated by commas -- (provides backward compatibility): box.cfg { listen = "127.0.0.1:3301, /unix.sock, 3302" } -- As an array which contains string URIs (unambiguous short form): box.cfg { listen = {"127.0.0.1:3301", "/unix.sock", "3302"} } -- As an array of tables with 'uri' field -- (may be extended with more fields in future): box.cfg { listen = { {uri = "127.0.0.1:3301"}, {uri = "/unix.sock"}, {uri = 3302} } } ```
-
mechanik20051988 authored
Previously, URI can be passed as a string, which contains one URI or several URIs separated by commas. Now URIs can be passed in different ways: as before, as a table which contains URI and it's parameters in "param" table, as a table which contains URI strings and URI tables. Also there are different ways to specify properties for URI: in a string which contains URI, after '?' delimiter, in a table which contains URI in "params" table, in "default_params" table if it is default parameters for all URIs. For this purposes new method `parse_many` was implemented in tarantool `uri` library. Also `parse` method was updated to make possible the same as new `parse_many` method but only for single URI. ```lua uri = require('uri') -- Single URI, passed as before uri.parse_many("/tmp/unix.sock") -- Single URI, with query paramters uri.parse_many("/tmp/unix.sock?q1=v1&q2=v2") -- Several URIs with parameters in one string, separated by commas uri.parse_many("/tmp/unix.sock_1?q=v, /tmp/unix.sock_2?q=v") -- Single URI passed in table, with additional parameters, passed -- in "params" table. This parameters overwrite parameters from -- URI string (q1 = "v2" in example below). uri.parse_many({"/tmp/unix.sock?q1=v1", params = {q1 = "v2"}}) -- For parse it's also works now uri.parse({"/tmp/unix.sock?q1=v1", params = {q1 = "v2"}}) -- Several URIs passed in table with default parameters, passed -- in "default_params" table, which are used for parameters, which -- not specified for URI (q3 parameter with "v3" value corresponds -- to all URIs, and used if there is no such parameter in URI). uri.parse_many({ "/tmp/unix.sock_1?q1=v1", { uri = "/tmp/unix.sock_2", params = { q2 = "v2" } }, default_params = { q3 = "v3" } }) ```
-
mechanik20051988 authored
Implement ability to parse a string, which contains several URIs separated by commas. Each URI can contain different query parameters after '?'. All created URIs saved in new implemented struct `uri_set`. Part of #5928
-
mechanik20051988 authored
Previously, the part of the URI string that comes after the first '?' was saved as a single unit in the field `query` as a part of `struct uri`. Now an array of URI paramters has been added to the uri structure, and query is subjected to the additional parsing and URI query parameters are extracted from it. The separator symbol between URI query parameters is '&', the separator symbol between parameter and it's value is '='. For example URI = "/tmp/unix.sock?q1=v11&q1=v12&q2=v2" has two parameters: parameter 'q1' with two values 'v11' and 'v12' and parameter 'q2' with value 'v2'. Part of #5928 Closes #1175
-
mechanik20051988 authored
In the future, it is planned to extend the URI structure to allow its passing with different options and in different formats (see next commit `uri: implement ability to parse URI query paramters` for example). For these purposes, it is planned to use functions that modify the source string, for example `strtok_r`, so we need to rework the URI structure to create copies of the string for each of the URI components. Part of #5928
-
mechanik20051988 authored
In the next commit we implement new `struct uri` and rename current `struct uri` to `struct uri_raw` which will be located in uri_parser.* files. Since git does not understand that we renamed file, if in the same commit we create file with the same name that file had before renaming, we will perform the renaming in a separate commit. Part of #5928
-
mechanik20051988 authored
Previously in case when unix socket URI with query didn't contain "unix/:" prefix, parsing of this URI was incorrect. For example "/unix.sock?q=v" was parsed into "path: /unix.sock" and "query: x=y" instead of "host: unix/", "service: /unix.sock", "unix: /unix.sock" and "query: x=y". Now parsing of unix socket URI is independent from "unix/:" prefix and correct. Pay attention, all parsing logic is realized in uri.rl file which compiled in uri.c using 'ragel'. Part of #5928
-
mechanik20051988 authored
The third parameter passed to the 'test:is' function is a message and usually should described what test checked.
-
- Dec 10, 2021
-
-
Andrey Saranchin authored
Currently, select/pairs/get look at an :array part of passed table, that is why different problems occurs when passed to select() table is not a regular array. Now we will check if passed table is not "clear dict" (not empty table without array part). Invalid queries like s:select{key = 'value'} will fail with an appropriate error, but the problems with dicts containing array part still remain (for example, s:select{1, key = 'value'} is the same as s:select{1}). Closes #6167
-
Vladimir Davydov authored
Without it `tarantoolctl rocks` would require luarocks to be installed on the system, which isn't always possible.
-
Vladimir Davydov authored
To avoid possible name clashes: e.g. we might want to add a module 'dump' to the built-in lib, but the symbol name dump_lua is already taken for 'jit.dump' - so better rename dump_lua to jit_dump_lua.
-
Vladimir Davydov authored
Currently, the symbol name is deducted from the filename, but it may lead to name clashes if different packages have modules with same names. Let's pass the symbol name explicitly to avoid that. This is needed to embed luarocks in static build.
-
Vladimir Davydov authored
This is needed to embed luarocks in static build.
-
Vladimir Davydov authored
Zlib is used in OpenSSL and in libCURL. Besides, we will need it for lua-zlib. So better define FindZLIB. Note, `add_library(ZLIB::ZLIB UNKNOWN IMPORTED)` and setting the corresponding properties in FindZLIB.cmake is needed to build libcurl, which depends on zlib.
-
- Dec 09, 2021
-
-
Sergey Ostanevich authored
Use of PROJECT_ prefix gives ability to build the project as a submodule of other projects.
-
Yaroslav Lobankov authored
This patch extends the 'integration.yml' workflow and adds a new workflow call for running tests to verify integration between tarantool and go-tarantool connector. Part of #5265 Part of #6056 Closes #6607
-
Sergey Ostanevich authored
Replication of data in the test should happened before the data presence test on the replica. Wait for lsn helper is used. Closes #6663
-
Georgiy Lebedev authored
Test for #6198 handles an edge case (box.schema.FIELD_MAX tuple field count), hence consuming a huge amount of memory (see #6684): mark it as long run. Closes #6684
-
- Dec 08, 2021
-
-
Vladislav Shpilevoy authored
This is a second attempt to stabilize #5568 test since 5105c2d7 ("test: fix flaky read_only_reason test"). It had several failures with various frequency. * test_read_only_reason_synchro() could see ro_reason as nil even after box.error.READONLY was raised (and some yields passed); * test_read_only_reason_orphan() could do the same; * `box.ctl.demote()` could raise error "box.ctl.demote does not support simultaneous invocations". The orphan failure couldn't be reproduced. It was caught only locally, so maybe it was just some unnoticed diff breaking the test. Failure of test_read_only_reason_synchro() could happen when demote() was called in a previous test case, then the current test case called promote(), then got box.error.READONLY on the replica, then that old demote() was delivered to replica, and the attempt to get ro_reason returned nil. It is attempted to be fixed with replication_synchro_quorum = 2, so master promote()/demote() will implicitly push the previous operation to the replica. Via term bump and quorum wait. Additionally, huge replication_synchro_timeout is added for manual promotions. Automatic promotion is retried so here the timeout is not so important. `box.ctl.demote` failure due to `simultaneous invocations` seems to be happening because the original auto-election win didn't finish limbo transition yet. Hence the instance calling demote() now would think it is called 'simultaneously' with another promote()/demote(). It is attempted to be fixed from 2 sides: - Add waiting for `not box.info.ro` on the leader node after auto-promotion. To ensure the limbo is taken by the leader; - The first option didn't help much, so `box.ctl.demote()` is simply called in a loop until it succeeds. Closes #6670
-
Alexey Vishnyakov authored
assert(cur < end) after mp_load_u8 in mp_check_binl was failing
-
Alexander Turenko authored
| [100%] Linking C static library libcurl-d.a | <...> | make[3]: *** No rule to make target `build/curl/dest/lib/libcurl.a', | needed by `test/unit/luaL_iterator.test'. Stop. The problem appears on Mac OS. It is a bit strange that we don't see it on Linux. However I didn't dig into this, just fixed the observed problem. Related: https://github.com/curl/curl/issues/2121 Fixes #6656
-
Serge Petrenko authored
The test fails quite often with one of the following results. Either [001] @@ -60,7 +60,7 @@ [001] ... [001] test_timeout() [001] --- [001] -- true [001] +- false [001] ... [001] test_run:cmd("switch default") [001] --- [001] Or [034] test_timeout() [034] --- [034] -- true [034] +- error: 'replicas are not in the follow status' [034] ... Both errors are caused by wait_cond checking saved `box.info.replication` values instead of actual `box.info.replication` output. Fix this. Also, the test's quite long for no reason. The wait_cond waiting for replication to break lasts a whole `replication_timeout`, which is excess. The test's idea, as stated in the commit that has introduced it (195d4462: Send relay heartbeat if wal changes won't be send) is to constantly relay some data to the remote peers and make it so their relays never send heartbeats. If we wait for a whole replication timeout between inserts, there's a high chance of peer relays waking up naturally (after replication_timeout passes). In this case the test tests nothing. Fix the issue by waiting for ~ 1/5 of replication_timeout in between the despatches. This also reduces test run time from ~4.5 to ~1.5 seconds on my machine. Remove the test from fragile list, since it shouldn't be flaky anymore. Closes #4940
-
- Dec 07, 2021
-
-
Georgiy Lebedev authored
vfork got deprecated on macOS: for now, change the vfork deprecation error to a warning until we find a suitable solution. We plan to review popen's design and get rid of vfork completely or change vfork to posix_spawn only on macOS in #6674. Closes #6576
-
Georgiy Lebedev authored
vfork got deprecated on macOS: change vfork to more portable posix_spawn. Needed for #6576
-
mechanik20051988 authored
If slab order of first several pools was equal to zero, all these pools added to same group with pools with slab order is equal to one. It's leds to incorrect behavior of `smfree` function, because this function relies on same slab order size of all pools in mempool group. Fix this and add assertion and test to check it. Closes #6659
-
- Dec 06, 2021
-
-
Georgiy Lebedev authored
Tuple field count overflow is not handled: before inserting, explicitly compare the current tuple size to box.schema.FIELD_MAX and set a newly introduced diagnostic message if overflow occurs. Closes #6198
-
Georgiy Lebedev authored
Tests inserting fields into tuples, causing it to append lots of nil's, work unacceptably slow: optimize mp_next. Needed for #6198
-
Georgiy Lebedev authored
On completion of compaction tasks we remove compacted run files created after the last checkpoint immediately to save disk space. In order to perform this optimization we compare the unused runs' dump LSN with the last checkpoint's one. But during replica's initial JOIN stage we set the LSN of all rows received from remote master to 0 (see box/box.cc/boostrap_journal_write). Considering that the LSN of an initial checkpoint is also 0, our optimization stops working, and we receive a huge disk space usage spike (as the unused run files will only get removed when garbage collection occurs). We should check the vinyl space engine's status and perform our optimization unconditionally if we are in replica's initial JOIN stage. Closes #6568
-