Commit Graph

263 Commits

Author SHA1 Message Date
tavplubix
f10930c9c8
Update clickhouse-test 2022-03-28 16:33:01 +03:00
mergify[bot]
2543e25b02
Merge branch 'master' into random-settings 2022-03-22 20:00:47 +00:00
Vladimir C
ac6fef5c70
Merge pull request #35124 from vdimir/ci-bugfix-validation 2022-03-22 17:34:15 +01:00
mergify[bot]
f22fddc3ec
Merge branch 'master' into random-settings 2022-03-21 11:52:21 +00:00
Kruglov Pavel
fbcc27a339
Merge pull request #27928 from Avogar/stress-test
Add backward compatibility check in stress test
2022-03-21 12:49:46 +01:00
avogar
b9496af3b3 Fix tests 2022-03-14 16:40:17 +00:00
vdimir
000a31df3b
no-random-settings for bugfix validate 2022-03-10 16:43:43 +00:00
avogar
b1a63cd727 Merge branch 'master' of github.com:ClickHouse/ClickHouse into random-settings 2022-03-09 17:09:32 +00:00
mergify[bot]
78c8029aeb
Merge branch 'master' into stress-test 2022-03-09 16:22:45 +00:00
Azat Khuzhin
8b64b41e65 tests: add check of left queries after each test
Look at log_comment/current_database for this check under --no-left-queries-check

v2: add no-left-queries-check tag support
Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
2022-03-09 17:29:32 +03:00
Azat Khuzhin
9a297ce3b6 tests: fix log_comment (extra quotes)
Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
2022-03-09 17:29:32 +03:00
avogar
722e0ea214 Fix clickhouse-test 2022-03-05 16:46:14 +00:00
Kruglov Pavel
607ec6c884
Fix style 2022-03-05 12:05:41 +03:00
Kruglov Pavel
dbba752398
Merge branch 'master' into stress-test 2022-03-04 18:33:37 +03:00
avogar
05b4bbeceb Add next batch of random settings in functional tests 2022-03-04 11:03:13 +00:00
mergify[bot]
c90d24e10b
Merge branch 'master' into random-settings 2022-03-03 13:07:12 +00:00
avogar
d25d83580a Fix tests 2022-03-02 16:33:21 +00:00
vdimir
fc5e941f79
Add option to clickhouse-test to skip aarch64 build 2022-03-02 14:18:24 +00:00
avogar
dbb29dd394 Fix tests 2022-02-28 12:17:44 +00:00
avogar
ba7f723961 Fix comments 2022-02-18 13:54:21 +00:00
avogar
90603ae549 Randomize just first batch of settings 2022-02-18 12:22:06 +00:00
Kruglov Pavel
e77319bf01
Merge branch 'master' into stress-test 2022-02-17 20:28:46 +03:00
avogar
48d036d3f9 Fix next batch of tests 2022-02-17 11:10:38 +00:00
Kruglov Pavel
33e4c703a1
Merge branch 'master' into random-settings 2022-02-16 13:38:15 +03:00
avogar
be5efc33d4 Fix more settings, add random settings for .sh tests 2022-02-16 10:35:46 +00:00
avogar
880780c7a8 Fix some tests 2022-02-11 17:15:56 +03:00
Kruglov Pavel
33c3b2d856
Better message 2022-02-08 18:38:41 +03:00
alesapin
18f08ed932
Revert "Revert "Add func tests run with s3"" 2022-02-01 10:20:06 +03:00
alexey-milovidov
cbfcd45be3
Revert "Add func tests run with s3" 2022-02-01 05:46:13 +03:00
alesapin
b6828f1b4a Supress some tests for S3 2022-01-31 19:09:25 +03:00
avogar
4bd6cd0b80 Add more settings, print settings if tests fails, add random settings to CLICKHOUSE_URL_PARAMS 2022-01-28 16:46:00 +03:00
Kruglov Pavel
1cdf49efed
More random settings
Co-authored-by: tavplubix <tavplubix@gmail.com>
2022-01-28 15:26:55 +03:00
avogar
4a005579cc Randomize some settings in functional tests 2022-01-28 14:26:50 +03:00
Kruglov Pavel
f3f414ae75
Fix style 2022-01-27 13:59:39 +03:00
Kruglov Pavel
b54bf18b27
Merge branch 'master' into stress-test 2022-01-25 14:35:42 +03:00
vdimir
e5613fce3c Support USE_* build flags in tests' tags 2022-01-19 12:21:51 +00:00
Kruglov Pavel
ffb6c5b37b
Merge branch 'master' into stress-test 2021-12-23 20:14:15 +03:00
Azat Khuzhin
b3f1951c15 clickhouse-test: avoid failing with UNKNOWN status in some cases
Like in:
- CREATE/DROP DATABASE failure
- Connection refused failure

Fixes: #32502
2021-12-12 18:48:54 +03:00
alexey-milovidov
8fdd7f329e
Merge pull request #32533 from azat/clickhouse-test-log-comment
clickhouse-test: use basename of the test for *.sh tests
2021-12-11 02:53:57 +03:00
Azat Khuzhin
2045a4f245 clickhouse-test: use basename of the test for *.sh tests 2021-12-10 21:45:29 +03:00
alesapin
a6e55b00e3
Revert "Revert "Split long tests into multiple checks"" 2021-12-10 18:39:02 +03:00
alesapin
dcbba460c1
Revert "Split long tests into multiple checks" 2021-12-10 18:38:42 +03:00
alesapin
8f8f65e6e0 Fix clickhouse test 2021-12-10 13:30:12 +03:00
alesapin
4c1babee05 Split long functional tests to multiple checks 2021-12-10 12:07:24 +03:00
Azat Khuzhin
d68d01988e clickhouse-test: apply --client-option in get_stacktraces_from_clickhouse() 2021-12-06 09:02:56 +03:00
Azat Khuzhin
9276384977 clickhouse-test: do not use random generator with shared state
Recently (#32094) test database had been overlapped, and random prefix
for database had been increased from 6 to 8.

But actually 6 bytes for random prefix should be enough (with existing
alphabet (0-9a-z) it is 36**6=2'176'782'336), and the real reason of
this overlap is that random generator by default uses shared state [1]:

    The functions supplied by this module are actually bound methods of
    a hidden instance of the random.Random class. You can instantiate your
    own instances of Random to get generators that don’t share state.

  [1]: https://docs.python.org/3/library/random.html

I've played a little bit with random in python, and using default random
generator it generates non-unique strings pretty fast, just in a few
runs, but using SystemRandom (that uses /dev/urandom) it takes ~1 minute.

Test:

```sh
    $ while /tmp/test.py | LANG=c sort -S5G | LANG=c uniq -d | tee /dev/stderr | wc -l | fgrep -q -x -c 0; do :; done
```

```python
    #!/usr/bin/env python3

    import multiprocessing
    import string
    import random

    def random_str(length=6):
        alphabet = string.ascii_lowercase + string.digits
        return ''.join(random.SystemRandom().choice(alphabet) for _ in range(length))

    def worker(_):
        print(random_str())

    with multiprocessing.Pool(processes=2) as pool:
        pool.map(worker, range(0, int(10e3)))
```

So let's switch to SystemRandom and use 6-byte prefix.
2021-12-03 01:29:23 +03:00
mergify[bot]
9c016d4e25
Merge branch 'master' into stress-test 2021-12-02 12:02:44 +00:00
Azat Khuzhin
cc8ebff212 Increase length of random database in clickhouse-test
In [1] there was one overlap with 6-byte prefix:

    $ pigz -cd clickhouse-server2.log.gz | fgrep  test_8a50uz | fgrep 'CREATE DATABASE' | fgrep comment | cut -d' ' -f7-
    <Debug> executeQuery: (from 0.0.0.0:0, user: ) (comment: 01018_insert_multiple_blocks_with_defaults.sh) /* ddl_entry=query-0000001951 */ CREATE DATABASE test_8a50uz UUID 'bb71f2ea-5ed3-466d-bb71-f2ea5ed3266d' ENGINE = Replicated('/test/clickhouse/db/test_8a50uz', '{shard}', '{replica}')
    <Debug> executeQuery: (from 0.0.0.0:0, user: ) (comment: 00098_k_union_all.sql) /* ddl_entry=query-0000003157 */ CREATE DATABASE test_8a50uz UUID '09cc030b-a4c1-4192-89cc-030ba4c1e192' ENGINE = Replicated('/test/clickhouse/db/test_8a50uz', '{shard}', '{replica}')
    <Error> executeQuery: Code: 82. DB::Exception: Database test_8a50uz already exists. (DATABASE_ALREADY_EXISTS) (version 21.12.1.8932) (from 0.0.0.0:0) (comment: 00098_k_union_all.sql) (in query: /* ddl_entry=query-0000003157 */ CREATE DATABASE test_8a50uz UUID '09cc030b-a4c1-4192-89cc-030ba4c1e192' ENGINE = Replicated('/test/clickhouse/db/test_8a50uz', '{shard}', '{replica}')), Stack trace (when copying this message, always include the lines below):

  [1]: https://clickhouse-test-reports.s3.yandex.net/32019/927b9cb1c6470b6d7cd86b4c3fd2078ff43b57df/functional_stateless_tests_(release,_databasereplicated).html#fail1
2021-12-01 22:39:42 +03:00
mergify[bot]
ce0c112586
Merge branch 'master' into stress-test 2021-11-25 11:09:26 +00:00
Alexey Milovidov
d604cf5573 Remove the infamous "unbundled" build 2021-11-21 13:58:26 +03:00