* docker/Dockerfile: add odyssey build type
To check bugs in asan builds of existing tests
Signed-off-by: rkhapov <r.khapov@ya.ru>
* test_scram.sh: fix asan run
Signed-off-by: rkhapov <r.khapov@ya.ru>
* sources/storage.c: fix strtol usage
The msg string can be not null-terminated.
Signed-off-by: rkhapov <r.khapov@ya.ru>
* docker/Dockerfile: add vim
Useful for in-container debugging
Signed-off-by: rkhapov <r.khapov@ya.ru>
* test-lag.sh: add odyssey start waiting
To ensure odyssey started in some slow builds, like asan
Signed-off-by: rkhapov <r.khapov@ya.ru>
* sources/storage.c: rewrite watchdog
It contained use-after-free bug because of spagetti-code
Preformed little refactor
A little bit slower (for each repl lag query we allocate new client),
but doesnt significant because replication
lag checking is performed once per second.
Signed-off-by: rkhapov <r.khapov@ya.ru>
* test-lag.sh: add ody-stop
seems like it was missed
Signed-off-by: rkhapov <r.khapov@ya.ru>
---------
Signed-off-by: rkhapov <r.khapov@ya.ru>
Co-authored-by: rkhapov <r.khapov@ya.ru>
This new command will help to run format on different envs
because of running formatting inside docker.
Previous make fmt will stay, but is not very suitable.
(cherry picked from commit d6dcd869f1)
Signed-off-by: rkhapov <r.khapov@yandex.ru>
* Makefile: use clang-format
clang-format-11 is older and requires waving
a dead chicken in modern systems.
Signed-off-by: rkhapov <r.khapov@ya.ru>
(cherry picked from commit b69027360f740aa196432ce1a93583d90b3b4a37)
Signed-off-by: rkhapov <r.khapov@ya.ru>
* Makefile: concurrency
concurrency 8 is too small for modern systems
+ fix apply_fmt to not format build directory, this will speed up
the apply_fmt command
Signed-off-by: rkhapov <r.khapov@ya.ru>
(cherry picked from commit 37961b5dfa774cd34f8ae680633e18fecd811e42)
Signed-off-by: rkhapov <r.khapov@ya.ru>
* fix github actions also
Signed-off-by: rkhapov <r.khapov@ya.ru>
(cherry picked from commit 00473a9af41be29445b353ef418efc6be0b7fb18)
Signed-off-by: rkhapov <r.khapov@ya.ru>
* use clang-format-17
Signed-off-by: rkhapov <r.khapov@ya.ru>
* remove run-clang-format
It will be moved into docker image later
Signed-off-by: rkhapov <r.khapov@ya.ru>
* clang-format: use run-clang-format from docker
Its more portable to use in different build envs
Signed-off-by: rkhapov <r.khapov@ya.ru>
* rm clang-format from install deps
Signed-off-by: rkhapov <r.khapov@ya.ru>
* apply new format
Signed-off-by: rkhapov <r.khapov@ya.ru>
---------
Signed-off-by: rkhapov <r.khapov@ya.ru>
Co-authored-by: rkhapov <r.khapov@ya.ru>
* Fix UNIX socket connection to server
target_session_attrs prevented usage usage of UNIX socket because
in some cases we need to pick any connection host. UNIX socket does
not posess one, so the code was SegFaulting.
* Move auth query server querying logic to separate file
* Refactor query code to support not only "auth_query" like queries
* Move storage logic to separate file & add storage watchdog
* Force several settings on starts
* Fix simple query parsing
* Fixed bugs
* Fix config reload
* Add tests
* Move cathcup logic to separate func
* Fix tests[2]
Co-authored-by: Andrey Borodin <amborodin@acm.org>
* do not hold repilation connections while online restart
* drop connection wtih rate (no more that 1 per sec)
* fix review
* eject info per-server
* use per thread global state to smoothly eject old connection
Co-authored-by: reshke <Kirill Reshke>
* fix scram build & tests, also make makefile a little bit more clear and parametrized
* fix fmt & fmt target better
* remove shell test from tests run
Co-authored-by: reshke <Kirill Reshke>