diff --git a/dev/local/ch-bench/README.md b/dev/local/ch-bench/README.md index 51e6207a..cb5e4462 100644 --- a/dev/local/ch-bench/README.md +++ b/dev/local/ch-bench/README.md @@ -20,12 +20,14 @@ The `scapedMetrics` depends on machine where node exporter runs, but it averages The `scrapeConfigUpdateInterval` and `scrapeConfigUpdatePercent` controls new "tags" generation. This does not impact metrics per second, but will generate more unique metrics. -To start: +## Attacking ``` docker compose up -d ``` +## Profiling + To collect profiles: ``` ./prof.sh @@ -36,4 +38,16 @@ This will emit profiles as `cpu.out` and `mem.out`: ``` go tool pprof -alloc_space mem.out go tool pprof cpu.out +``` + +## Checking + +To check that points actually made to database, one can use following query: +```clickhouse +SELECT toDateTime(toStartOfSecond(timestamp)) as ts, COUNT() +FROM metrics_points +WHERE timestamp < (now() - toIntervalSecond(5)) +GROUP BY ts +ORDER BY ts DESC +LIMIT 15; ``` \ No newline at end of file