2021-09-12 12:35:27 +00:00
|
|
|
-- Tags: race
|
|
|
|
|
2022-07-13 08:44:53 +00:00
|
|
|
-- { echo }
|
2020-11-30 13:53:04 +00:00
|
|
|
SELECT count() > 0 FROM system.stack_trace WHERE query_id != '';
|
2022-07-13 08:44:53 +00:00
|
|
|
-- opimization for not reading /proc/self/task/{}/comm and avoid sending signal
|
|
|
|
SELECT countIf(thread_id > 0) > 0 FROM system.stack_trace;
|
|
|
|
-- optimization for trace
|
2022-09-12 11:56:52 +00:00
|
|
|
SELECT count(trace) > 0 FROM system.stack_trace WHERE length(trace) > 0 LIMIT 1;
|
2022-07-13 08:44:53 +00:00
|
|
|
-- optimization for query_id
|
|
|
|
SELECT length(query_id) > 0 FROM system.stack_trace WHERE query_id != '' LIMIT 1;
|
|
|
|
-- optimization for thread_name
|
|
|
|
SELECT length(thread_name) > 0 FROM system.stack_trace WHERE thread_name != '' LIMIT 1;
|
2022-07-14 06:06:47 +00:00
|
|
|
-- enough rows (optimizations works "correctly")
|
|
|
|
SELECT count() > 100 FROM system.stack_trace;
|