Commit Graph

5406 Commits

Author SHA1 Message Date
Smita Kulkarni
2f73bf48b8 Added config to integration test test_endpoint_macro_substitution - Allow macro substitution in endpoint 2023-01-02 11:43:19 +01:00
SmitaRKulkarni
f9a3aeb172
Merge branch 'master' into 40951_Allow_macro_substitution_in_endpoint 2022-12-30 10:43:14 +01:00
robot-clickhouse
c09d1bc758 Automatic style fix 2022-12-29 15:16:50 +00:00
Smita Kulkarni
8cc3b2e26c Fixed integration flaky test issue by specifying hdfs client in each test- Allow macro substitution in endpoint 2022-12-29 16:10:06 +01:00
Nikita Mikhaylov
ffaff7167b
Fix flaky tests (#44690) 2022-12-29 14:32:10 +01:00
Alexey Milovidov
9378194320
Merge pull request #44688 from ClickHouse/improve-odbc-test
Improve odbc test
2022-12-29 15:40:47 +03:00
Azat Khuzhin
90b707d130 tests: more fixes for test_keeper_auth
Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
2022-12-29 09:29:24 +01:00
Alexey Milovidov
f7b2b961f7
Merge pull request #44667 from azat/tests/integration/dmesg-fix
Move dmesg dumping out from runner to ci-runner.py
2022-12-29 01:56:34 +03:00
Alexey Milovidov
23ea273f73 Edit another test 2022-12-28 19:49:57 +01:00
Alexey Milovidov
edd78da0cb ODBC test: avoid poisoning other tests 2022-12-28 19:45:01 +01:00
Alexey Milovidov
0263499b0c
Merge pull request #44666 from azat/tests/integration/kazoo-stop
tests/integration: add missing kazoo client termination
2022-12-28 21:20:14 +03:00
Azat Khuzhin
03f80bae90 Move dmesg dumping out from runner to ci-runner.py
runner is used by developers to run tests, while ci-runner.py is used
only by CI scripts, and to avoid requiring CAP_SYSLOG for manual dmesg
clear/dump had been moved.

Also for manual runs this can be done manually.

Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
2022-12-28 15:47:46 +01:00
Vitaly Baranov
8a2fbbe88c
Merge pull request #43947 from azat/backups/dedup
RFC: Add ability to disable deduplication for BACKUP
2022-12-28 15:24:53 +01:00
Alexey Milovidov
1b4121459d
Merge pull request #44645 from ClickHouse/keeper-test-fix
Fix flaky test `test_keeper_multinode_simple`
2022-12-28 16:38:17 +03:00
Azat Khuzhin
bc6adc88c8 tests/integration: add workaround for a bug in kazoo driver
Refs: python-zk/kazoo#688
Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
2022-12-28 10:52:49 +01:00
Vitaly Baranov
b211dff013 Increase the create table timeout in test "test_backup_restore_on_cluster". 2022-12-28 00:17:19 +01:00
Nikita Mikhaylov
00ecf6dd05 Better 2022-12-27 17:04:47 +00:00
Nikita Mikhaylov
ce6264b684 Done 2022-12-27 17:03:57 +00:00
Azat Khuzhin
e1ad5cee7e tests/integration: add missing kazoo client termination
pytest play games with logging output [1].

  [1]: https://github.com/pytest-dev/pytest/issues/5502

But this does not actually affect ClickHouse tests, the only reason is
that the kazoo client is not stopped correctly without calling
kazoo.client.KazooClient.stop(), and that's why you can see the
following messages:

<details>

    test_storage_rabbitmq/test.py::test_rabbitmq_big_message --- Logging error ---
    Traceback (most recent call last):
      File "/usr/local/lib/python3.8/dist-packages/kazoo/protocol/connection.py", line 179, in _socket_error_handling
        yield
      File "/usr/local/lib/python3.8/dist-packages/kazoo/protocol/connection.py", line 659, in _connect
        self._socket = self.handler.create_connection(
      File "/usr/local/lib/python3.8/dist-packages/kazoo/handlers/threading.py", line 178, in create_connection
        return utils.create_tcp_connection(socket, *args, **kwargs)
      File "/usr/local/lib/python3.8/dist-packages/kazoo/handlers/utils.py", line 265, in create_tcp_connection
        sock = module.create_connection(address, timeout_at)
      File "/usr/lib/python3.8/socket.py", line 808, in create_connection
        raise err
      File "/usr/lib/python3.8/socket.py", line 796, in create_connection
        sock.connect(sa)
    socket.timeout: timed out

    During handling of the above exception, another exception occurred:

    Traceback (most recent call last):
      File "/usr/local/lib/python3.8/dist-packages/kazoo/protocol/connection.py", line 579, in _connect_attempt
        read_timeout, connect_timeout = self._connect(host, hostip, port)
      File "/usr/local/lib/python3.8/dist-packages/kazoo/protocol/connection.py", line 659, in _connect
        self._socket = self.handler.create_connection(
      File "/usr/lib/python3.8/contextlib.py", line 131, in __exit__
        self.gen.throw(type, value, traceback)
      File "/usr/local/lib/python3.8/dist-packages/kazoo/protocol/connection.py", line 182, in _socket_error_handling
        raise ConnectionDropped("socket connection error: %s" % (err,))
    kazoo.exceptions.ConnectionDropped: socket connection error: None

    During handling of the above exception, another exception occurred:

    Traceback (most recent call last):
      File "/usr/lib/python3.8/logging/__init__.py", line 1088, in emit
        stream.write(msg + self.terminator)
    ValueError: I/O operation on closed file.
    Call stack:
      File "/usr/lib/python3.8/threading.py", line 890, in _bootstrap
        self._bootstrap_inner()
      File "/usr/lib/python3.8/threading.py", line 932, in _bootstrap_inner
        self.run()
      File "/usr/lib/python3.8/threading.py", line 870, in run
        self._target(*self._args, **self._kwargs)
      File "/usr/local/lib/python3.8/dist-packages/kazoo/protocol/connection.py", line 512, in zk_loop
        if retry(self._connect_loop, retry) is STOP_CONNECTING:
      File "/usr/local/lib/python3.8/dist-packages/kazoo/retry.py", line 126, in __call__
        return func(*args, **kwargs)
      File "/usr/local/lib/python3.8/dist-packages/kazoo/protocol/connection.py", line 552, in _connect_loop
        status = self._connect_attempt(host, hostip, port, retry)
      File "/usr/local/lib/python3.8/dist-packages/kazoo/protocol/connection.py", line 622, in _connect_attempt
        self.logger.warning('Connection dropped: %s', e)
    Message: 'Connection dropped: %s'
    Arguments: (ConnectionDropped('socket connection error: None'),)

</details>

Which eventually leads to incorrectly parsed report.

This patch is an addition to the `logging.raiseExceptions=False` - #44618

Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
2022-12-27 17:01:06 +01:00
Azat Khuzhin
c9c590071d Add ability to disable deduplication for BACKUP
Right now BACKUP omit similar files, and will not allow to use this
backup as a regular table, and usually those similar files are quite
small (i.e. columns.txt).

So by using `BACKUP TO S3() deduplicate_files=0` you will be possible to
use `ATTACH TABLE` directly from S3.

P.S. right now it is possible only for the table with one part, since,
usually, there is nothing to deduplicate (if the columns are different).

v2: Add deduplicate_files into metadata
Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
2022-12-27 15:56:06 +01:00
Alexey Milovidov
7e447592b1
Merge pull request #44618 from azat/tests/integration/pytest-logging-fix
tests/integration: suppress exceptions during logging (due to pytest)
2022-12-27 14:33:37 +03:00
Alexey Milovidov
79d43c836a
Merge pull request #44572 from ClickHouse/fix-hdfs-test
Fix HDFS test
2022-12-27 14:31:00 +03:00
Alexey Milovidov
41fc65b47b
Merge pull request #44573 from ClickHouse/fix-distributed-queries-stress
Fix test_distributed_queries_stress
2022-12-27 14:30:28 +03:00
Azat Khuzhin
8b2ed0e3cd tests/integration: disable logging.raiseExceptions
Due to pytest play games with logging [1] it is better to ignore it.

  [1]: https://github.com/pytest-dev/pytest/issues/5502

This is due to incorrect kazoo client usage (not all clients calls
stop())

Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
2022-12-26 22:57:54 +01:00
Alexey Milovidov
a92a9b4d55
Merge pull request #44535 from azat/tests/integration-dmesg
tests: capture dmesg in integration tests
2022-12-26 23:49:02 +03:00
Alexey Milovidov
a06c8268ea Remove the offender 2022-12-26 11:28:26 +01:00
Alexey Milovidov
f9f0f9446d Fix distributed_queries_stress 2022-12-25 09:46:51 +01:00
robot-clickhouse
19f05d4fb4 Automatic style fix 2022-12-25 08:38:02 +00:00
Alexey Milovidov
cbf140633b Fix HDFS test 2022-12-25 09:30:20 +01:00
Smita Kulkarni
84362461fb Updated test to use macro substitution for hdfs disk - Allow macro substitution in endpoint 2022-12-23 16:07:56 +01:00
Azat Khuzhin
69fadd2193 tests: capture dmesg in integration tests
Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
2022-12-23 15:50:10 +01:00
Smita Kulkarni
3d62bc2635 Allow macro substitution in endpoint of disks
Implementation:
* Updated to substitute macros in endpoint for all disks (s3, hfs, web).
Testing:
* Added an integration test test/integration/test_endpoint_macro_substitution.
2022-12-23 15:09:24 +01:00
Mikhail f. Shiryaev
6d0cd35cd0
Ignore exit code 1 for tar in integration tests 2022-12-23 13:08:59 +01:00
Vladimir C
7482ea54ab
Merge pull request #43972 from ClickHouse/vdimir/tmp-data-in-fs-cache-2 2022-12-23 11:59:27 +01:00
kssenii
11c0aa189a Better error message 2022-12-22 15:29:35 +01:00
Nikolai Kochetov
773de7a8a6
Merge pull request #44472 from CurtizJ/fix-mutations
Fix mutations with setting `max_streams_for_merge_tree_reading`
2022-12-22 14:05:20 +01:00
vdimir
182b34c11e
Fixes 2022-12-22 10:22:57 +00:00
vdimir
511e8d698d
Rename config param tmp_cache -> temporary_data_in_cache 2022-12-22 10:22:56 +00:00
vdimir
d30d25dbbe
Temporary files evict fs cache 2022-12-22 10:22:49 +00:00
Anton Popov
5d6064cd28 better config in test 2022-12-21 11:35:11 +00:00
Anton Popov
4b7f1e0cf2 fix mutations with setting 'max_streams_for_merge_tree_reading' 2022-12-21 01:59:53 +00:00
alesapin
80cae1aa3d Better 2022-12-20 17:37:03 +01:00
alesapin
33389f01e6 Disable tsan assertion for test 2022-12-20 17:33:08 +01:00
Konstantin Bogdanov
93375fc3e5
Merge pull request #44411 from thevar1able/fix-settings-constraints
Fix settings constraints
2022-12-20 10:19:07 +01:00
Konstantin Bogdanov
a094af9a49
Lint 2022-12-20 04:00:45 +01:00
Konstantin Bogdanov
b07001e7d7
Add a test 2022-12-20 03:26:31 +01:00
Antonio Andelic
55dd591392 Try restarting ZK cluster on failed connection 2022-12-19 09:28:59 +00:00
Antonio Andelic
0162632275
Merge pull request #44306 from ClickHouse/another-fix-for-test-server-reload
Another fix `test_server_reload`
2022-12-19 09:14:03 +01:00
Nikolay Degterinsky
7a29bf0e4c
Merge pull request #43993 from evillique/fix_settings_constraints
Fix CREATE query constraints
2022-12-16 18:01:04 +01:00
Anton Popov
8b9b8b083c
Merge pull request #43726 from CurtizJ/optimize-storage-s3
Improve performance of storage `S3` with large number of small files
2022-12-16 14:38:10 +01:00