Skip to content

Un-flake 02524_fuzz_and_fuss_2 - #67867

Merged
rschu1ze merged 1 commit into
ClickHouse:masterfrom
rschu1ze:fuzz-and-fuss
Aug 6, 2024
Merged

rschu1ze merged 1 commit into
ClickHouse:masterfrom
rschu1ze:fuzz-and-fuss

Conversation

@rschu1ze

@rschu1ze rschu1ze commented Aug 5, 2024

Copy link
Copy Markdown
Member

Fails very sporadically (ca. 2x / year) in tsan builds.

This PR increases setting max_execution_time = '3' to max_execution_time = '9'.

Logs show nothing suspicious except running parallel aggregation queries by another test. 02524_fuzz_and_fuss_2 uses max_threads = 3, so the test might simply starve.

https://s3.amazonaws.com/clickhouse-test-reports/0/3221b651da16cd868350a1aff022ba71a1a15f3c/stateless_tests__tsan__s3_storage__[2_5].html

https://s3.amazonaws.com/clickhouse-test-reports/0/1fde5b7bfa1b1a6a0d67258be5e7ef855b730559/stateless_tests__tsan__s3_storage__[2_4].html

Changelog category (leave one):

  • Not for changelog (changelog entry is not required)

@robot-clickhouse robot-clickhouse added the pr-not-for-changelog This PR should not be mentioned in the changelog label Aug 5, 2024
@alexey-milovidov alexey-milovidov added the 🍃 green ci 🌿 Fixing flaky tests in CI label Aug 5, 2024
@alexey-milovidov alexey-milovidov self-assigned this Aug 5, 2024
@robot-ch-test-poll3

robot-ch-test-poll3 commented Aug 5, 2024 •

Copy link
Copy Markdown
Contributor

This is an automated comment for commit 05395ac with description of existing statuses. It's updated for the latest CI running

✅ Click here to open a full report in a separate page

Successful checks
Check nameDescriptionStatus
BuildsThere's no description for the check yet, please add it to tests/ci/ci_config.py:CHECK_DESCRIPTIONS✅ success
Fast testNormally this is the first check that is ran for a PR. It builds ClickHouse and runs most of stateless functional tests, omitting some. If it fails, further checks are not started until it is fixed. Look at the report to see which tests fail, then reproduce the failure locally as described here✅ success
Flaky testsChecks if new added or modified tests are flaky by running them repeatedly, in parallel, with more randomization. Functional tests are run 100 times with address sanitizer, and additional randomization of thread scheduling. Integration tests are run up to 10 times. If at least once a new test has failed, or was too long, this check will be red. We don't allow flaky tests, read the doc✅ success
Stateless testsRuns stateless functional tests for ClickHouse binaries built in various configurations -- release, debug, with sanitizers, etc✅ success
Stress testRuns stateless functional tests concurrently from several clients to detect concurrency-related errors✅ success
Style checkRuns a set of checks to keep the code style clean. If some of tests failed, see the related log from the report✅ success
Unit testsRuns the unit tests for different release types✅ success
Upgrade checkRuns stress tests on server version from last release and then tries to upgrade it to the version from the PR. It checks if the new server can successfully startup without any errors, crashes or sanitizer asserts✅ success

@rschu1ze
rschu1ze added this pull request to the merge queue Aug 6, 2024
Merged via the queue into ClickHouse:master with commit f9320b8 Aug 6, 2024
@rschu1ze
rschu1ze deleted the fuzz-and-fuss branch August 6, 2024 09:45
@robot-ch-test-poll1 robot-ch-test-poll1 added the pr-synced-to-cloud The PR is synced to the cloud repo label Aug 6, 2024
pull Bot pushed a commit to peijunlin2008/ClickHouse that referenced this pull request Jul 28, 2026
The test pinned max_execution_time = '9' on a one-row
INSERT INTO data_a_02187 SELECT * FROM system.one. That setting is a
wall-clock deadline, not a work budget: it is registered per query in
ProcessList.cpp and enforced by a background thread in
CancellationChecker.cpp. On Stateless tests (amd_msan, WasmEdge) the
statement was descheduled past its own deadline under load and the test
failed with

  Code: 159. Timeout exceeded: elapsed 11056.432 ms, maximum: 9000 ms.

The failing job's server log shows the query logging its last pipeline
line, then nothing at all for 9.000839 s, then the cancellation, while
2396 lines from 120 other query ids land in the same window. Nothing in
the statement got slower.

Removing the pin does not weaken the test. It was added as a test for
issue ClickHouse#38729 (Block structure mismatch in Pipes stream), its reference
file is empty, it expects no server or client error, and EXPLAIN
PIPELINE of the statement is byte-identical with and without the token.
The test stays bounded by the harness --timeout of 600 s.

Raising the value again was not an option: PR ClickHouse#67867 already raised this
same pin from 3 to 9 for the same class of failure. Over the last 30
days this test file takes p50 2170 ms and p95 3210 ms on that flavour,
and 24 of 8051 passing runs already exceed 9000 ms for the whole file,
so no constant makes a per-statement 9 s cap reliable.

Verified with three arms on one binary: as-is rc=0, pin removed rc=0,
and as a live control the pin forced to 0.001 rc=159. The test then
passes 1/1 through the harness and 50/50 with randomized settings.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

🍃 green ci 🌿 Fixing flaky tests in CI pr-not-for-changelog This PR should not be mentioned in the changelog pr-synced-to-cloud The PR is synced to the cloud repo

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants