Open ai-tmpst opened 4 weeks ago
I'll deploy the Clockhouse logs on our website, so there will be manual testing and we can move the task to 0.9.
Things to test:
mmap_log_buffer_size
for i in $(seq 1 30); do kill -SIGSTOP 8384 && sleep 10 && kill -SIGCONT 8384; done
Something like this we need in tests. Now it can lead to incorrect tail position.
To verify the correct operation of the access log transmission from the Tempesta FW ring buffer, mapped to userspace, to a Clickhouse server via a user-space utility
utils/tfw_logger
. This test will ensure that access logs are correctly generated by Tempesta FW, and transmitted to the Clickhouse server without data loss or corruption.Clickhouse has SQL-like query syntax.
Access log table creation:
CREATE TABLE IF NOT EXISTS access_log (timestamp DateTime64, address IPv6, method UInt8, version UInt8, status UInt16, response_content_length UInt32, response_time UInt32, vhost String, uri String, referer String, user_agent String, dropped_events UInt64, PRIMARY KEY(timestamp))
For tests I used Clickhouse client/server downloaded as
curl https://clickhouse.com/ | sh
. But I think it would be better to install the server from distro repositories.