Commit Graph

27 Commits

Author SHA1 Message Date
Yury Frolov 02f3144265
Enabled writing stats in Prometheus format. (#346)
* Early implementation

* Added description for gauges

* Added prometheus lib finding to Cmake

* Fixed FindProm comments

* Small changes

* free to prom_free

* Moved metrics to separate file

* Refactored & added new methods to prom_metrics

* Refactored cron.c to use prom_metrics.h

* Refactored CMake & odyssey.h

* Added new metrics

* Small refactoring

* Small method renaming

* Small fix in init

* Added methods for use in od_cron_stats_cb

* Small fixes

* Refactored metrics to use separate collectors

* Small fix

* Passing metrics to od_cron_stat_cb now.

* Removed unused imports

* Removed old od_log calls

* Removed TODO

* Revert "Removed old od_log calls"

This reverts commit 60000c8321.

* Uncommented od_log calls

* Added processed clients field to metrics

* Refactored metrics init

* Fixed write_stat

* Added method for worker stats

* Added method for worker stat to metrics header file

* Refactored worker stat method

* Reverted changes in odyssey.h

* Added writing metrics to od_worker

* Added new method to logger

Method provides writing big strings to log without formatting.

* Fixed prometheus log writing

* More fixes

* Fixed log writing

* Fixed log calls

* Added TODO

* Added assertion whether prom.h found

* Fixed no format logger method

Now logs follow log format

* Fixed logger

* Added log_stats_prom option to config

* Renamed od_logger_write_no_fmt to od_logger_write_plain

* Formatted

* More ifdefs

* Added memory deallocating in od_cron_stop

* Updated configuration.md

* Removed outdated TODO

* Changed label

* Formatted
2021-08-17 17:07:16 +05:00
reshke af703ed0a3 STATEMENT pooling 2021-07-08 15:51:42 +05:00
reshke a9e9ade846 autoconfigure number of workers 2021-05-20 17:26:19 +05:00
reshke a78664e7b7 Add password_passthrough option to route 2021-05-19 17:18:49 +05:00
reshke df178bc3cf fix cli options && add log to stodut option 2021-05-15 17:02:19 +05:00
reshke 2019c6419e odyssey configuration from CLI 2021-05-14 15:36:29 +05:00
reshke 94b4859df6 fallback to reuse client token to backend auth 2021-04-30 17:09:01 +05:00
reshke dc44b323d1 return error if ldap connection establishment failed, rebind ldap
connection in case of server failture
2021-04-29 12:51:07 +05:00
reshke 74623edfb5 LDAP auth in od 2021-04-28 17:54:56 +05:00
Andrey Borodin 9f78f451ec Apply fmt 2021-04-19 22:25:36 +05:00
Andrey Borodin d0c3238cc4 Preformat query for backward compatibility and fix some misplaces ) 2021-03-16 10:59:14 +05:00
Andrey Borodin 1d4599f025 Flip back online restart 2021-03-05 09:42:45 +05:00
Andrey Borodin 4b90eb8971 Fix injection in auth_query 2021-03-05 09:42:45 +05:00
kirill reshke f0fee5feea
using limited channel in async log worker (#285)
* using limited channel in async log worker

* fmt

Co-authored-by: reshke <Kirill Reshke>
2021-03-01 17:01:04 +05:00
reshke 9c3d23a815 rename param 2021-02-25 13:40:15 +05:00
reshke ade1b4c111 wait for pending data 2021-02-20 22:52:12 +05:00
reshke 107f0ae171 add pool idle in transaction setting 2021-02-12 13:03:06 +05:00
reshke e4bea27f66 introduse pool client idle timeout in session pooling mode 2021-02-12 02:30:03 +05:00
kirill reshke b546551bb8
do not hold repilation connections while online restart + drop conn rate logic (#266)
* 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>
2021-01-23 18:49:54 +05:00
kirill reshke 9bed642b30
drop old server connection while online restrat in session pooling mode (#263)
Co-authored-by: reshke <Kirill Reshke>
2021-01-21 16:24:43 +05:00
kirill reshke 8a3831b082
Makefile build targets + quantileins memfree fix + online restart condition recheck (#261) 2021-01-14 11:54:16 +05:00
Daniil Zakhlystov e97f7e1f1c
Add compression toggle to config, cmake && Add dependencies to BuildDebian (#234)
* Add compression option to config

* Add BUILD_COMPRESSION option to cmake

* Escape identifiers

* Add preprocessing directives for OD_BUILD_COMPRESSION

* Add dependencies for BuildDebian

* apply fmt

Co-authored-by: root <root@ubuntu-build-machine.ru-central1.internal>
2020-11-23 16:55:42 +05:00
kirill reshke bc568250bf
odyssey tests with asan, little test refactor (#225)
* odyssey tests with asan

* better headers, rework test

Co-authored-by: reshke <Kirill Reshke>
2020-10-27 13:47:25 +05:00
reshke 57a9e84150 show errors per route 2020-09-03 14:04:28 +05:00
reshke 20e97cae09 drop steal users connections on restart 2020-09-02 11:49:14 +05:00
reshke 52b0abb647 fix infinte loop + add signals tests 2020-08-10 13:39:09 +05:00
reshke f030093484 use SO_REUSEPORT to graceful shutdown 2020-08-10 13:39:09 +05:00