Skip to content

[DOC] Remove invalid statement about Zookeeper#22

Closed
buremba wants to merge 1 commit intoClickHouse:masterfrom
buremba:patch-1
Closed

[DOC] Remove invalid statement about Zookeeper#22
buremba wants to merge 1 commit intoClickHouse:masterfrom
buremba:patch-1

Conversation

@buremba
Copy link

@buremba buremba commented Jun 17, 2016

FWIU, Zookeeper is not just for replication, it's also used for distributed tables. Clickhouse stores metadata in Zookeeper and query them when a SELECT statement is executed so this statement is invalid.

FWIU, Zookeeper is not just for replication, it's also used for distributed tables. Clickhouse stores metadata in Zookeeper and query them when a SELECT statement is executed so this statement is invalid.
@alexey-milovidov
Copy link
Member

No, SELECTs from Distributed tables don't touch ZooKeeper.

@slw slw mentioned this pull request Nov 9, 2017
vitlibar pushed a commit to vitlibar/ClickHouse that referenced this pull request Oct 6, 2019
Akazz added a commit that referenced this pull request Jun 30, 2020
alexey-milovidov added a commit that referenced this pull request Jul 7, 2020
…12248)

* Added a test

* Update ErrorCodes.cpp

* More hardening

* More hardening

* Move reading from RabbitMQ into background task

* Fix access rights: cannot grant DDL when allow_ddl=0

* Add tests

* Add test test_allow_ddl.

* Added failing test

* Remove the usage of obsolete setting

* Whitespace

* Added a test

* Allow to ALTER partition key in some cases

* Slightly more safe

* Only allow Enum extension within the same width

* Update test

* Added failing test for Replicated table

* Fix clang-tidy

* Whitespace

* Write partition key changes to ZooKeeper

* Typos

* Implement for ReplicatedMergeTree

* Added test reference

* Added missing ORDER BY in test

* Fix integration test

* Fix error in addMonths with floating point argument

* Fix error in addMonths with floating point argument

* Fix overflow in function "neighbor"

* Whitespace

* Whitespace

* Fix ORDER BY tuple with COLLATE on const column

* clickhouse-local: logging flags fixes

* clickhouse-local: use std::filesystem::equivalent

* Limit /proc/cpuinfo metrics to linux only

* Feature 8074 (#12014)

* refs #8074 1: start to stream

* refs final check format and spell

* refs final check format and spell

* refs #8074 fix up link to sql-reference/functions/other-functions

* Bump idna from 2.9 to 2.10 in /docs/tools

Bumps [idna](https://github.com/kjd/idna) from 2.9 to 2.10.
- [Release notes](https://github.com/kjd/idna/releases)
- [Changelog](https://github.com/kjd/idna/blob/master/HISTORY.rst)
- [Commits](kjd/idna@v2.9...v2.10)

Signed-off-by: dependabot-preview[bot] <[email protected]>

* make a short test for DateTime

* Fixup

* DOCS-636 Synchronized some edits from EN to RU (#11941)

* [review][clickhousedocs][translate] DOCSUP-1351: Edit and translate to Russian (#129)

* DOCSUP-1351: Add blockSerializedSize (RU)

* DOCSUP-1351: Fix blockSerializedSize description by function description template.

* DOCSUP-1351: PR8756- Update Distributed engine section.

* DOCSUP-1351: PR9076-Show Queries more like MySQL did.

* DOCSUP-1351: PR#9919-system.tables improvements (total_rows/total_bytes/storage_policy)

* DOCSUP-1351: (ru) blockSerializedSize remake by template.

* DOCSUP-1351: PR#9598-Add function arrayReduceInRange and update arrayReduce function.

* DOCSUP-1351: PR#9598 Fix arrayReduce and arrayReduceInRanges sections by template.

* DOCSUP-1351: Some fixes.

* DOCSUP-1351: Some fixes.

Co-authored-by: romanzhukov <[email protected]>

* CLICKHOUSEDOCS-636: Minor changes.

Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Roman Bug <[email protected]>
Co-authored-by: romanzhukov <[email protected]>

* Use ConcurentBoundedQueue instead of vector

* Temporary enable debug logs when releasing docs

* Better docker images list

* [docs] improve stable releases discovery

* Update contrib/jemalloc-cmake/CMakeLists.txt

* Remove libevent library

* Automated backporting machinery (#12029)

* Add automated cherry-pick machinery

* Added script for backporting machinery

* Implement dry-run mode

* Comment old methods

* Fix python2

* Add ya.make for sandbox tasks

* Remove old stuff

* Move writing to RabbitMQ into background task

* Add TLB misses perf counters.

* Update ThreadProfileEvents.cpp

* Fake change in dockerfile

* Fix tuple nullable comparison.

* Fix access rights: cannot grant INTROSPECTION when allow_introspection_functions=0.

* fixup

* Update ThreadProfileEvents.cpp

* Fix test.

* Added test.

* Fix and simplify code

* Fix test.

* Update ITransformingStep.h

* Fix "Sharding key is not deterministic" message

* Do not check *optimize_skip_unused_shards_nesting w/o *optimize_skip_unused_shards

This will avoid supperior log message in case of
*optimize_skip_unused_shards_nesting already disables it.
And also it is logical.

* Remove test that is not supported by "Arcadia" build system

* Make topK return Enum for Enum types

* parse metadata in parallel when loading tables

* Fix build

* fixup

* Update ThreadProfileEvents.cpp

* Update browse-code.md (#12047)

* Update browse-code.md

纠正了一些翻译错误。

* Update browse-code.md

Co-authored-by: Ivan Blinkov <[email protected]>

* Bump python-slugify from 1.2.6 to 4.0.1 in /docs/tools

Bumps [python-slugify](https://github.com/un33k/python-slugify) from 1.2.6 to 4.0.1.
- [Release notes](https://github.com/un33k/python-slugify/releases)
- [Changelog](https://github.com/un33k/python-slugify/blob/master/CHANGELOG.md)
- [Commits](un33k/python-slugify@1.2.6...4.0.1)

Signed-off-by: dependabot-preview[bot] <[email protected]>

* Update ThreadProfileEvents.cpp

* Update README.md

* Fix typo (#12046)

* Fix test_allow_introspection.

* Try fix labda tuple(LC) argument.

* Test image changes

* Try fix labda tuple(LC) argument.

* Add pvs studio to images

* Added test.

* fix low card types in merge join (#12035)

* Update contrib/poco to ClickHouse-Extras/poco #22 (#12037)

* Updated ClickHouse-Extras/poco #22

* Fix defaultValueOfArgumentType

* Added test.

* Update cpu_synthetic.xml

* Moves task shall be started if new storage policy needs them.

* Added test for automatic start of background move task.

* Add ability to run any image version from packager and runner

* Check type of filter for prewhere.

* Check type of filter for prewhere.

* Check type of filter for prewhere.

* Check type of filter for prewhere.

* Added test.

* Try fix pk in tuple performance

Possible approach for fixing #10574

The problem is that prepared sets are built correctly, it is a hash map of key -> set
where key is a hash of AST and list of data types (when we a list of
tuples of literals).

However, when the key is built from the index to try and find if there
exists a prepared set that would match it looks for data types of the
primary key (see how data_types is populated) because the primary key
has only one field (v in my example) it can not find the prepared set.

The patch looks for any prepared indexes where data types match for the
subset of fields found in primary key, we are not interested in other
fields anyway for the purpose of primary key pruning.

* Fix partial revokes (complex cases).

* Changelog for 20.3.11, 12

* simple changelog script

* bump CI

* Fix tests.

* Add explicit test for a case where AST hashes collide for different prepared sets

* [blog] add RSS feed (#12064)

* [blog] add rss feed

* better title

* Update CHANGELOG.md

Co-authored-by: Ivan Blinkov <[email protected]>

* bump ci

* Moved useless S3 logging to TRACE level.

* Add a test to cover non-const tuple elemenets (just in case)

* Bump

* Update query-complexity.md

Remove a note about read limits applied on threads level.

* Update query-complexity.md

* Update query-complexity.md

* Update query-complexity.md

* DOCS-609: max_server_memory_usage (#11771)

* Revolg DOCSUP-1000 add max server memory usage setting (#125)

* Add max_server_memory_usage setting, delete max_memory_usage_for_all_queries setting.

* Syntax fixed

* Apply suggestions from code review

Co-authored-by: BayoNet <[email protected]>

* Doc for the max_server_memory_usage setting. Updates.

Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-609: Minor fixes.

* CLICKHOUSEDOCS-609: Actualized position of the setting.

Co-authored-by: olgarev <[email protected]>
Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>

* Add force_primary_key to a pk in tuple test

* DOCS-510: runningAccumulate (#12061)

* asiana21-DOCSUP-797 (#117)

* docs(runningAccumulate): the function description is added

* docs(runningAccumulate): the function description is modified

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* docs(runningAccumulate): some changes

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* docs(runningAccumulate): added ru translation

Co-authored-by: asiana21 <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-510: Minor fix.

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: Ivan Blinkov <[email protected]>

* CLICKHOUSEDOCS-510: Fixed links.

Co-authored-by: AsiaKorushkina <[email protected]>
Co-authored-by: asiana21 <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Ivan Blinkov <[email protected]>

* Remove const specifier to allow auto-move (clangtidy)

* Rewrite Set lookup to make it more readable

* [docs] Sync zh/development/build-osx.md from EN (#12071)

* ISSUES-4006 support first for ALTER ADD|MODIFY COLUMN

* Update deb image

* Don't download image twice

* Remove garbage from images

* bump ci

* fixup

* DOCS-635: Translated the EN version of the AvroConfluent format description (#11930)

* DOCSUP-1350 (#128)

* edited EN version

* add EN and RU translation

* minor changes

* CLICKHOUSEDOCS-635: Updated the description.

Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Evgenia Sudarikova <[email protected]>

* Fix tests.

* Better PVS image

* DOCS-605: Description for the always_fetch_merged_part setting (#11921)

* Revolg DOCSUP-998 Document the always_fetch_merged_part setting (#123)

* Add always_fetch_merged_part setting

* revolg-DOCSUP-998-add_always_fetch_merged_part_setting link fixed

* Apply suggestions from code review

Co-authored-by: BayoNet <[email protected]>

* Add always_fetch_merged_part setting. Updates.

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* Add always_fetch_merged_part setting. Updates.

Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-605: Minor fixes.

* CLICKHOUSEDOCS-605: Added Plausible to Adopters.

* Update docs/ru/operations/settings/settings.md

Co-authored-by: alesapin <[email protected]>

* Update docs/en/operations/settings/settings.md

Co-authored-by: alesapin <[email protected]>

* CLICKHOUSEDOCS-605: Fixed access rights description.

Co-authored-by: olgarev <[email protected]>
Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: alesapin <[email protected]>

* Update Dockerfile

* revert e9d3c48

* [blog] 'Package Repository Behind CDN' post (#12082)

* support iframes from DataLens

* initial blog post text

* Improve REVOKE command: now it requires only grant/admin option for only
access which will be revoked.
REVOKE ALL FROM user1 now revokes all granted roles.

* Fix limiting the number of threads for VIEW.

* Update tips.md

* Added test.

* Remove pvs studio from images list

* Better shutdown and conversion

* Reverse arguments

* Fix result_rows and result_bytes metrics for selects.

* Fix result_rows and result_bytes metrics for selects.

* improve breadcrumbs markup

* Fix tests.

* Less race conditions

* [docker] install ca-certificates before the first apt-get update (#12095)

* [docker] install ca-certificates before first apt-get update

* Update Dockerfile

* DOCS-522: max_parser_depth (#12097)

* asiana21-DOCSUP-925-max_parser_depth (#132)

* docs(max_parser_depth): added the setting description

* docs(max_parser_depth): some changes

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* docs(max_parser_depth): added ru translation

* docs(max_parser_depth): removed quotation marks

Co-authored-by: asiana21 <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-522: Fixed the link.

Co-authored-by: AsiaKorushkina <[email protected]>
Co-authored-by: asiana21 <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>

* Added results for AWS Lightsail

* (typo) in doc (#12099)

* Added test.

* Create codeql-analysis.yml

* Tiny fixes

* Create anchore-analysis.yml

* Update README.md

* Fix test (#12088)

* Test for a fixed issue #10668, related to input_format_allow_errors_num in CSV

* Add unbundled mode flag

* Remove LC converting to Arrow.

* Remove LC converting to Arrow.

* Move skip lists to clickhouse-test

* Remove LC converting to Arrow.

* More verbose message about skip

* Make skip-list optional

* Added test.

* Add type column in system.disks

* Update clickhouse-test

* Update 01355_CSV_input_format_allow_errors.sh

* Added a showcase of minimal Docker image

* Added a comment

* Added a comment

* Added a comment

* Formatting

* contrib/unixodbc-cmake: Fix build when UNBUNDLED

target_compile_definitions may only set INTERFACE properties on IMPORTED targets

* Fix version column in replicated version collapsing merge tree (#12121)

* poco-cmake: Fix Poco::Data::ODBC target when UNBUNDLED

By default IMPORTED target has a scope in the directory in which it is created
and below. This leads to the following issues when building UNBUNDLED:

Target "clickhouse" links to target "Poco::Data::ODBC" but the target was not
found.  Perhaps a find_package() call is missing for an IMPORTED target, or an
ALIAS target is missing?

* Add missed <atomic> include in ProxyListConfiguration

* Improve performace of reading in order of sorting key. (#11696)

* simplify reading in order of sorting key

* add perf test for reading many parts

* Revert "simplify reading in order of sorting key"

This reverts commit 7267d7c.

* add threshold for preliminary merge for reading in order

* better threshold

* limit threads in test

* Normalize "pid" file handling #3501

* Update StatusFile.cpp

* Remove harmful code from "geoDistance" #12117

* Fix warnings from CodeQL

* Added a test

* Minor modification

* Fix potential overflow in integer division #12119

* Added a test

* Whitespace

* Added a test for #4211

* Attempt to fix "Arcadia" build

* Rename test

* Update arraySum.cpp

* ILIKE operator (#12125)

* Integrated CachingAllocator into MarkCache

* fixed build errors

* reset func hotfix

* upd: Fixing build

* updated submodules links

* fix 2

* updating grabber allocator proto

* updating lost work

* updating CMake to use concepts

* some other changes to get it building (integration into MarkCache)

* further integration into caches

* updated Async metrics, fixed some build errors

* and some other errors revealing

* added perfect forwarding to some functions

* fix: forward template

* fix: constexpr modifier

* fix: FakePODAllocator missing member func

* updated PODArray constructor taking alloc params

* fix: PODArray overload with n restored

* fix: FakePODAlloc duplicating alloc() func

* added constexpr variable for alloc_tag_t

* split cache values by allocators, provided updates

* fix: memcpy

* fix: constexpr modifier

* fix: noexcept modifier

* fix: alloc_tag_t for PODArray constructor

* fix: PODArray copy ctor with different alloc

* fix: resize() signature

* updating to lastest working master

* syncing with 273267

* first draft version

* fix: update Searcher to case-insensitive

* added ILIKE test

* fixed style errors, updated test, split like and ilike,  added notILike

* replaced inconsistent comments

* fixed show tables ilike

* updated missing test cases

* regenerated ya.make

* Update 01355_ilike.sql

Co-authored-by: myrrc <[email protected]>
Co-authored-by: alexey-milovidov <[email protected]>

Co-authored-by: Alexey Milovidov <[email protected]>
Co-authored-by: kssenii <[email protected]>
Co-authored-by: Vitaly Baranov <[email protected]>
Co-authored-by: Andrew Onyshchuk <[email protected]>
Co-authored-by: Mikhail Gaidamaka <[email protected]>
Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
Co-authored-by: Alexander Kuzmenkov <[email protected]>
Co-authored-by: Nikolai Kochetov <[email protected]>
Co-authored-by: Ivan Blinkov <[email protected]>
Co-authored-by: alesapin <[email protected]>
Co-authored-by: BayoNet <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Roman Bug <[email protected]>
Co-authored-by: romanzhukov <[email protected]>
Co-authored-by: tavplubix <[email protected]>
Co-authored-by: Alexander Kuzmenkov <[email protected]>
Co-authored-by: Ivan <[email protected]>
Co-authored-by: Nikita Mikhaylov <[email protected]>
Co-authored-by: Azat Khuzhin <[email protected]>
Co-authored-by: chengy8934 <[email protected]>
Co-authored-by: MicrochipQ <[email protected]>
Co-authored-by: Artem Zuikov <[email protected]>
Co-authored-by: Alexander Kazakov <[email protected]>
Co-authored-by: Vladimir Chebotarev <[email protected]>
Co-authored-by: Nicolae Vartolomei <[email protected]>
Co-authored-by: filimonov <[email protected]>
Co-authored-by: olgarev <[email protected]>
Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: AsiaKorushkina <[email protected]>
Co-authored-by: asiana21 <[email protected]>
Co-authored-by: BohuTANG <[email protected]>
Co-authored-by: zhang2014 <[email protected]>
Co-authored-by: Evgenia Sudarikova <[email protected]>
Co-authored-by: Anton Popov <[email protected]>
Co-authored-by: manmitya <[email protected]>
Co-authored-by: Nikolai Kochetov <[email protected]>
Co-authored-by: Mikhail Filimonov <[email protected]>
Co-authored-by: Anton Ivashkin <[email protected]>
Co-authored-by: Ilya Yatsishin <[email protected]>
Co-authored-by: tavplubix <[email protected]>
Co-authored-by: Matwey V. Kornilov <[email protected]>
Co-authored-by: myrrc <[email protected]>
Co-authored-by: myrrc <[email protected]>
alexey-milovidov added a commit that referenced this pull request Jul 7, 2020
…2260)

* Whitespace

* Fix ORDER BY tuple with COLLATE on const column

* clickhouse-local: logging flags fixes

* clickhouse-local: use std::filesystem::equivalent

* Limit /proc/cpuinfo metrics to linux only

* Feature 8074 (#12014)

* refs #8074 1: start to stream

* refs final check format and spell

* refs final check format and spell

* refs #8074 fix up link to sql-reference/functions/other-functions

* Bump idna from 2.9 to 2.10 in /docs/tools

Bumps [idna](https://github.com/kjd/idna) from 2.9 to 2.10.
- [Release notes](https://github.com/kjd/idna/releases)
- [Changelog](https://github.com/kjd/idna/blob/master/HISTORY.rst)
- [Commits](kjd/idna@v2.9...v2.10)

Signed-off-by: dependabot-preview[bot] <[email protected]>

* make a short test for DateTime

* Fixup

* DOCS-636 Synchronized some edits from EN to RU (#11941)

* [review][clickhousedocs][translate] DOCSUP-1351: Edit and translate to Russian (#129)

* DOCSUP-1351: Add blockSerializedSize (RU)

* DOCSUP-1351: Fix blockSerializedSize description by function description template.

* DOCSUP-1351: PR8756- Update Distributed engine section.

* DOCSUP-1351: PR9076-Show Queries more like MySQL did.

* DOCSUP-1351: PR#9919-system.tables improvements (total_rows/total_bytes/storage_policy)

* DOCSUP-1351: (ru) blockSerializedSize remake by template.

* DOCSUP-1351: PR#9598-Add function arrayReduceInRange and update arrayReduce function.

* DOCSUP-1351: PR#9598 Fix arrayReduce and arrayReduceInRanges sections by template.

* DOCSUP-1351: Some fixes.

* DOCSUP-1351: Some fixes.

Co-authored-by: romanzhukov <[email protected]>

* CLICKHOUSEDOCS-636: Minor changes.

Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Roman Bug <[email protected]>
Co-authored-by: romanzhukov <[email protected]>

* Use ConcurentBoundedQueue instead of vector

* Temporary enable debug logs when releasing docs

* Better docker images list

* [docs] improve stable releases discovery

* Update contrib/jemalloc-cmake/CMakeLists.txt

* Remove libevent library

* Automated backporting machinery (#12029)

* Add automated cherry-pick machinery

* Added script for backporting machinery

* Implement dry-run mode

* Comment old methods

* Fix python2

* Add ya.make for sandbox tasks

* Remove old stuff

* Move writing to RabbitMQ into background task

* Add TLB misses perf counters.

* Update ThreadProfileEvents.cpp

* Fake change in dockerfile

* Fix tuple nullable comparison.

* Fix access rights: cannot grant INTROSPECTION when allow_introspection_functions=0.

* fixup

* Update ThreadProfileEvents.cpp

* Fix test.

* Added test.

* Fix and simplify code

* Fix test.

* Update ITransformingStep.h

* Fix "Sharding key is not deterministic" message

* Do not check *optimize_skip_unused_shards_nesting w/o *optimize_skip_unused_shards

This will avoid supperior log message in case of
*optimize_skip_unused_shards_nesting already disables it.
And also it is logical.

* Fix function if with FixedString arguments of different sizes

* Add multiIf

* Fix error

* Remove test that is not supported by "Arcadia" build system

* Fix constraints check for constant columns

* Make topK return Enum for Enum types

* parse metadata in parallel when loading tables

* Fix error

* Fix build

* fixup

* Update ThreadProfileEvents.cpp

* Update browse-code.md (#12047)

* Update browse-code.md

纠正了一些翻译错误。

* Update browse-code.md

Co-authored-by: Ivan Blinkov <[email protected]>

* Bump python-slugify from 1.2.6 to 4.0.1 in /docs/tools

Bumps [python-slugify](https://github.com/un33k/python-slugify) from 1.2.6 to 4.0.1.
- [Release notes](https://github.com/un33k/python-slugify/releases)
- [Changelog](https://github.com/un33k/python-slugify/blob/master/CHANGELOG.md)
- [Commits](un33k/python-slugify@1.2.6...4.0.1)

Signed-off-by: dependabot-preview[bot] <[email protected]>

* Update ThreadProfileEvents.cpp

* Update README.md

* Fix typo (#12046)

* Fix test_allow_introspection.

* Try fix labda tuple(LC) argument.

* Test image changes

* Try fix labda tuple(LC) argument.

* Add pvs studio to images

* Added test.

* fix low card types in merge join (#12035)

* Update contrib/poco to ClickHouse-Extras/poco #22 (#12037)

* Updated ClickHouse-Extras/poco #22

* Fix defaultValueOfArgumentType

* Added test.

* Update cpu_synthetic.xml

* Moves task shall be started if new storage policy needs them.

* Added test for automatic start of background move task.

* Add ability to run any image version from packager and runner

* Check type of filter for prewhere.

* Check type of filter for prewhere.

* Check type of filter for prewhere.

* Check type of filter for prewhere.

* Added test.

* Try fix pk in tuple performance

Possible approach for fixing #10574

The problem is that prepared sets are built correctly, it is a hash map of key -> set
where key is a hash of AST and list of data types (when we a list of
tuples of literals).

However, when the key is built from the index to try and find if there
exists a prepared set that would match it looks for data types of the
primary key (see how data_types is populated) because the primary key
has only one field (v in my example) it can not find the prepared set.

The patch looks for any prepared indexes where data types match for the
subset of fields found in primary key, we are not interested in other
fields anyway for the purpose of primary key pruning.

* Fix partial revokes (complex cases).

* Changelog for 20.3.11, 12

* simple changelog script

* bump CI

* Fix tests.

* Add explicit test for a case where AST hashes collide for different prepared sets

* [blog] add RSS feed (#12064)

* [blog] add rss feed

* better title

* Update CHANGELOG.md

Co-authored-by: Ivan Blinkov <[email protected]>

* bump ci

* Moved useless S3 logging to TRACE level.

* Add a test to cover non-const tuple elemenets (just in case)

* Bump

* Update query-complexity.md

Remove a note about read limits applied on threads level.

* Update query-complexity.md

* Update query-complexity.md

* Update query-complexity.md

* DOCS-609: max_server_memory_usage (#11771)

* Revolg DOCSUP-1000 add max server memory usage setting (#125)

* Add max_server_memory_usage setting, delete max_memory_usage_for_all_queries setting.

* Syntax fixed

* Apply suggestions from code review

Co-authored-by: BayoNet <[email protected]>

* Doc for the max_server_memory_usage setting. Updates.

Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-609: Minor fixes.

* CLICKHOUSEDOCS-609: Actualized position of the setting.

Co-authored-by: olgarev <[email protected]>
Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>

* Add force_primary_key to a pk in tuple test

* DOCS-510: runningAccumulate (#12061)

* asiana21-DOCSUP-797 (#117)

* docs(runningAccumulate): the function description is added

* docs(runningAccumulate): the function description is modified

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* docs(runningAccumulate): some changes

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* docs(runningAccumulate): added ru translation

Co-authored-by: asiana21 <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-510: Minor fix.

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: Ivan Blinkov <[email protected]>

* CLICKHOUSEDOCS-510: Fixed links.

Co-authored-by: AsiaKorushkina <[email protected]>
Co-authored-by: asiana21 <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Ivan Blinkov <[email protected]>

* Remove const specifier to allow auto-move (clangtidy)

* Rewrite Set lookup to make it more readable

* [docs] Sync zh/development/build-osx.md from EN (#12071)

* ISSUES-4006 support first for ALTER ADD|MODIFY COLUMN

* Update deb image

* Don't download image twice

* Remove garbage from images

* bump ci

* Changelog for 20.1, 20.4

* fixup

* DOCS-635: Translated the EN version of the AvroConfluent format description (#11930)

* DOCSUP-1350 (#128)

* edited EN version

* add EN and RU translation

* minor changes

* CLICKHOUSEDOCS-635: Updated the description.

Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Evgenia Sudarikova <[email protected]>

* Fix tests.

* Better PVS image

* DOCS-605: Description for the always_fetch_merged_part setting (#11921)

* Revolg DOCSUP-998 Document the always_fetch_merged_part setting (#123)

* Add always_fetch_merged_part setting

* revolg-DOCSUP-998-add_always_fetch_merged_part_setting link fixed

* Apply suggestions from code review

Co-authored-by: BayoNet <[email protected]>

* Add always_fetch_merged_part setting. Updates.

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* Add always_fetch_merged_part setting. Updates.

Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-605: Minor fixes.

* CLICKHOUSEDOCS-605: Added Plausible to Adopters.

* Update docs/ru/operations/settings/settings.md

Co-authored-by: alesapin <[email protected]>

* Update docs/en/operations/settings/settings.md

Co-authored-by: alesapin <[email protected]>

* CLICKHOUSEDOCS-605: Fixed access rights description.

Co-authored-by: olgarev <[email protected]>
Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: alesapin <[email protected]>

* Update Dockerfile

* revert e9d3c48

* [blog] 'Package Repository Behind CDN' post (#12082)

* support iframes from DataLens

* initial blog post text

* Improve REVOKE command: now it requires only grant/admin option for only
access which will be revoked.
REVOKE ALL FROM user1 now revokes all granted roles.

* Fix limiting the number of threads for VIEW.

* Update tips.md

* Added test.

* Remove pvs studio from images list

* Better shutdown and conversion

* Reverse arguments

* Fix result_rows and result_bytes metrics for selects.

* Fix result_rows and result_bytes metrics for selects.

* improve breadcrumbs markup

* Fix tests.

* Less race conditions

* [docker] install ca-certificates before the first apt-get update (#12095)

* [docker] install ca-certificates before first apt-get update

* Update Dockerfile

* DOCS-522: max_parser_depth (#12097)

* asiana21-DOCSUP-925-max_parser_depth (#132)

* docs(max_parser_depth): added the setting description

* docs(max_parser_depth): some changes

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* docs(max_parser_depth): added ru translation

* docs(max_parser_depth): removed quotation marks

Co-authored-by: asiana21 <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-522: Fixed the link.

Co-authored-by: AsiaKorushkina <[email protected]>
Co-authored-by: asiana21 <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>

* Added results for AWS Lightsail

* (typo) in doc (#12099)

* Added test.

* Create codeql-analysis.yml

* Tiny fixes

* Create anchore-analysis.yml

* Changelog for 20.5

* Update CHANGELOG.md

* Update README.md

* Fix test (#12088)

* Test for a fixed issue #10668, related to input_format_allow_errors_num in CSV

* Add unbundled mode flag

* Remove LC converting to Arrow.

* Remove LC converting to Arrow.

* Move skip lists to clickhouse-test

* Remove LC converting to Arrow.

* More verbose message about skip

* Make skip-list optional

* Added test.

* Add type column in system.disks

* Update clickhouse-test

* Fix handling dependency of table with ENGINE=Dictionary on dictionary.

* Add test.

* Update 01355_CSV_input_format_allow_errors.sh

* Update CHANGELOG.md

* Added a showcase of minimal Docker image

* Added a comment

* Added a comment

* Added a comment

* Formatting

* contrib/unixodbc-cmake: Fix build when UNBUNDLED

target_compile_definitions may only set INTERFACE properties on IMPORTED targets

* Fix version column in replicated version collapsing merge tree (#12121)

* poco-cmake: Fix Poco::Data::ODBC target when UNBUNDLED

By default IMPORTED target has a scope in the directory in which it is created
and below. This leads to the following issues when building UNBUNDLED:

Target "clickhouse" links to target "Poco::Data::ODBC" but the target was not
found.  Perhaps a find_package() call is missing for an IMPORTED target, or an
ALIAS target is missing?

* Add missed <atomic> include in ProxyListConfiguration

* Improve performace of reading in order of sorting key. (#11696)

* simplify reading in order of sorting key

* add perf test for reading many parts

* Revert "simplify reading in order of sorting key"

This reverts commit 7267d7c.

* add threshold for preliminary merge for reading in order

* better threshold

* limit threads in test

* Normalize "pid" file handling #3501

* Update StatusFile.cpp

* New ISO8601 year modificators for formatDateTime

* Added a test

* Remove harmful code from "geoDistance" #12117

* Update formatDateTime.cpp

* Fix warnings from CodeQL

* Added a test

* Minor modification

* Update libdivide to the latest master

* Replace exit to abort in libdivide

* Fix potential overflow in integer division #12119

* Added a test

* Whitespace

* Added a test for #4211

* Attempt to fix "Arcadia" build

* Rename test

* Update arraySum.cpp

* Make code clearer: use enum instead of `bool internal`.

* Update StorageDictionary.h

* Update StorageDictionary.h

* ILIKE operator (#12125)

* Integrated CachingAllocator into MarkCache

* fixed build errors

* reset func hotfix

* upd: Fixing build

* updated submodules links

* fix 2

* updating grabber allocator proto

* updating lost work

* updating CMake to use concepts

* some other changes to get it building (integration into MarkCache)

* further integration into caches

* updated Async metrics, fixed some build errors

* and some other errors revealing

* added perfect forwarding to some functions

* fix: forward template

* fix: constexpr modifier

* fix: FakePODAllocator missing member func

* updated PODArray constructor taking alloc params

* fix: PODArray overload with n restored

* fix: FakePODAlloc duplicating alloc() func

* added constexpr variable for alloc_tag_t

* split cache values by allocators, provided updates

* fix: memcpy

* fix: constexpr modifier

* fix: noexcept modifier

* fix: alloc_tag_t for PODArray constructor

* fix: PODArray copy ctor with different alloc

* fix: resize() signature

* updating to lastest working master

* syncing with 273267

* first draft version

* fix: update Searcher to case-insensitive

* added ILIKE test

* fixed style errors, updated test, split like and ilike,  added notILike

* replaced inconsistent comments

* fixed show tables ilike

* updated missing test cases

* regenerated ya.make

* Update 01355_ilike.sql

Co-authored-by: myrrc <[email protected]>
Co-authored-by: alexey-milovidov <[email protected]>

* add parseDateTimeBestEffortUS function (#12028)

* add function parseDateTimeBestEffortUS
* add test
* add doc

Co-authored-by: alexey-milovidov <[email protected]>

* Cleanup changelog (half done). Now it is acceptable #12104

* Cleanup changelog (half done). Now it is more acceptable #12104

* Cleanup changelog (half done). Now it is more acceptable #12104

* Cleanup changelog (half done). Additions requested by @filimonov #12104

Co-authored-by: Alexey Milovidov <[email protected]>
Co-authored-by: Andrew Onyshchuk <[email protected]>
Co-authored-by: Mikhail Gaidamaka <[email protected]>
Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
Co-authored-by: Alexander Kuzmenkov <[email protected]>
Co-authored-by: Nikolai Kochetov <[email protected]>
Co-authored-by: Ivan Blinkov <[email protected]>
Co-authored-by: alesapin <[email protected]>
Co-authored-by: BayoNet <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Roman Bug <[email protected]>
Co-authored-by: romanzhukov <[email protected]>
Co-authored-by: kssenii <[email protected]>
Co-authored-by: tavplubix <[email protected]>
Co-authored-by: Alexander Kuzmenkov <[email protected]>
Co-authored-by: Ivan <[email protected]>
Co-authored-by: Vitaly Baranov <[email protected]>
Co-authored-by: Nikita Mikhaylov <[email protected]>
Co-authored-by: Azat Khuzhin <[email protected]>
Co-authored-by: chengy8934 <[email protected]>
Co-authored-by: MicrochipQ <[email protected]>
Co-authored-by: Artem Zuikov <[email protected]>
Co-authored-by: Alexander Kazakov <[email protected]>
Co-authored-by: Vladimir Chebotarev <[email protected]>
Co-authored-by: Nicolae Vartolomei <[email protected]>
Co-authored-by: filimonov <[email protected]>
Co-authored-by: olgarev <[email protected]>
Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: AsiaKorushkina <[email protected]>
Co-authored-by: asiana21 <[email protected]>
Co-authored-by: BohuTANG <[email protected]>
Co-authored-by: zhang2014 <[email protected]>
Co-authored-by: Evgenia Sudarikova <[email protected]>
Co-authored-by: Anton Popov <[email protected]>
Co-authored-by: manmitya <[email protected]>
Co-authored-by: Nikolai Kochetov <[email protected]>
Co-authored-by: Mikhail Filimonov <[email protected]>
Co-authored-by: Anton Ivashkin <[email protected]>
Co-authored-by: Ilya Yatsishin <[email protected]>
Co-authored-by: tavplubix <[email protected]>
Co-authored-by: Matwey V. Kornilov <[email protected]>
Co-authored-by: vivarum <[email protected]>
Co-authored-by: myrrc <[email protected]>
Co-authored-by: myrrc <[email protected]>
Co-authored-by: flynn <[email protected]>
alexey-milovidov added a commit that referenced this pull request Jul 7, 2020
)

* Make topK return Enum for Enum types

* parse metadata in parallel when loading tables

* Fix error

* Fix build

* fixup

* Update ThreadProfileEvents.cpp

* Update browse-code.md (#12047)

* Update browse-code.md

纠正了一些翻译错误。

* Update browse-code.md

Co-authored-by: Ivan Blinkov <[email protected]>

* Bump python-slugify from 1.2.6 to 4.0.1 in /docs/tools

Bumps [python-slugify](https://github.com/un33k/python-slugify) from 1.2.6 to 4.0.1.
- [Release notes](https://github.com/un33k/python-slugify/releases)
- [Changelog](https://github.com/un33k/python-slugify/blob/master/CHANGELOG.md)
- [Commits](un33k/python-slugify@1.2.6...4.0.1)

Signed-off-by: dependabot-preview[bot] <[email protected]>

* Update ThreadProfileEvents.cpp

* Update README.md

* Add a test with negative priority in test_distributed_load_balancing

* Fix typo (#12046)

* Fix test_allow_introspection.

* Try fix labda tuple(LC) argument.

* Test image changes

* Try fix labda tuple(LC) argument.

* Add pvs studio to images

* Added test.

* fix low card types in merge join (#12035)

* Update contrib/poco to ClickHouse-Extras/poco #22 (#12037)

* Updated ClickHouse-Extras/poco #22

* Fix defaultValueOfArgumentType

* Added test.

* Update cpu_synthetic.xml

* Moves task shall be started if new storage policy needs them.

* Added test for automatic start of background move task.

* Add ability to run any image version from packager and runner

* Check type of filter for prewhere.

* Check type of filter for prewhere.

* Check type of filter for prewhere.

* Check type of filter for prewhere.

* Added test.

* Try fix pk in tuple performance

Possible approach for fixing #10574

The problem is that prepared sets are built correctly, it is a hash map of key -> set
where key is a hash of AST and list of data types (when we a list of
tuples of literals).

However, when the key is built from the index to try and find if there
exists a prepared set that would match it looks for data types of the
primary key (see how data_types is populated) because the primary key
has only one field (v in my example) it can not find the prepared set.

The patch looks for any prepared indexes where data types match for the
subset of fields found in primary key, we are not interested in other
fields anyway for the purpose of primary key pruning.

* Fix partial revokes (complex cases).

* Changelog for 20.3.11, 12

* simple changelog script

* bump CI

* Fix tests.

* Add explicit test for a case where AST hashes collide for different prepared sets

* [blog] add RSS feed (#12064)

* [blog] add rss feed

* better title

* Update CHANGELOG.md

Co-authored-by: Ivan Blinkov <[email protected]>

* bump ci

* Moved useless S3 logging to TRACE level.

* Add a test to cover non-const tuple elemenets (just in case)

* Bump

* Update query-complexity.md

Remove a note about read limits applied on threads level.

* Update query-complexity.md

* Update query-complexity.md

* Update query-complexity.md

* DOCS-609: max_server_memory_usage (#11771)

* Revolg DOCSUP-1000 add max server memory usage setting (#125)

* Add max_server_memory_usage setting, delete max_memory_usage_for_all_queries setting.

* Syntax fixed

* Apply suggestions from code review

Co-authored-by: BayoNet <[email protected]>

* Doc for the max_server_memory_usage setting. Updates.

Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-609: Minor fixes.

* CLICKHOUSEDOCS-609: Actualized position of the setting.

Co-authored-by: olgarev <[email protected]>
Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>

* Add force_primary_key to a pk in tuple test

* DOCS-510: runningAccumulate (#12061)

* asiana21-DOCSUP-797 (#117)

* docs(runningAccumulate): the function description is added

* docs(runningAccumulate): the function description is modified

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* docs(runningAccumulate): some changes

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* docs(runningAccumulate): added ru translation

Co-authored-by: asiana21 <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-510: Minor fix.

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: Ivan Blinkov <[email protected]>

* CLICKHOUSEDOCS-510: Fixed links.

Co-authored-by: AsiaKorushkina <[email protected]>
Co-authored-by: asiana21 <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Ivan Blinkov <[email protected]>

* Remove const specifier to allow auto-move (clangtidy)

* Rewrite Set lookup to make it more readable

* [docs] Sync zh/development/build-osx.md from EN (#12071)

* ISSUES-4006 support first for ALTER ADD|MODIFY COLUMN

* Update deb image

* Don't download image twice

* Remove garbage from images

* bump ci

* Changelog for 20.1, 20.4

* fixup

* DOCS-635: Translated the EN version of the AvroConfluent format description (#11930)

* DOCSUP-1350 (#128)

* edited EN version

* add EN and RU translation

* minor changes

* CLICKHOUSEDOCS-635: Updated the description.

Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Evgenia Sudarikova <[email protected]>

* Fix tests.

* Better PVS image

* DOCS-605: Description for the always_fetch_merged_part setting (#11921)

* Revolg DOCSUP-998 Document the always_fetch_merged_part setting (#123)

* Add always_fetch_merged_part setting

* revolg-DOCSUP-998-add_always_fetch_merged_part_setting link fixed

* Apply suggestions from code review

Co-authored-by: BayoNet <[email protected]>

* Add always_fetch_merged_part setting. Updates.

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* Add always_fetch_merged_part setting. Updates.

Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-605: Minor fixes.

* CLICKHOUSEDOCS-605: Added Plausible to Adopters.

* Update docs/ru/operations/settings/settings.md

Co-authored-by: alesapin <[email protected]>

* Update docs/en/operations/settings/settings.md

Co-authored-by: alesapin <[email protected]>

* CLICKHOUSEDOCS-605: Fixed access rights description.

Co-authored-by: olgarev <[email protected]>
Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: alesapin <[email protected]>

* Update Dockerfile

* revert e9d3c48

* [blog] 'Package Repository Behind CDN' post (#12082)

* support iframes from DataLens

* initial blog post text

* Improve REVOKE command: now it requires only grant/admin option for only
access which will be revoked.
REVOKE ALL FROM user1 now revokes all granted roles.

* Fix limiting the number of threads for VIEW.

* Update tips.md

* Added test.

* Remove pvs studio from images list

* Better shutdown and conversion

* Reverse arguments

* Fix result_rows and result_bytes metrics for selects.

* Fix result_rows and result_bytes metrics for selects.

* improve breadcrumbs markup

* Fix tests.

* fix segfault with -StateResample combinators

* Less race conditions

* fix test with buffer table

* [docker] install ca-certificates before the first apt-get update (#12095)

* [docker] install ca-certificates before first apt-get update

* Update Dockerfile

* DOCS-522: max_parser_depth (#12097)

* asiana21-DOCSUP-925-max_parser_depth (#132)

* docs(max_parser_depth): added the setting description

* docs(max_parser_depth): some changes

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* docs(max_parser_depth): added ru translation

* docs(max_parser_depth): removed quotation marks

Co-authored-by: asiana21 <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-522: Fixed the link.

Co-authored-by: AsiaKorushkina <[email protected]>
Co-authored-by: asiana21 <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>

* Rewrite curl dependency in a more ch compatible way

- add support of unbundled curl
- add CURL::libcurl libraries
- avoid explicit linkage of daemon with curl (added with sentry)
- set CACHE variables for non-direct users:
  - mariadb-connector-c
  - aws-s3-cmake
  - sentry-native

Cc: @alexey-milovidov
Cc: @alesapin (requires docker image update)
Cc: @abyss7

Refs: #11300
Refs: #8011
Refs: #8905

v2: replace cmake/find/curl.cmake with proper contrib/curl-cmake (as
pointed by @abyss7, cmake/find/*.cmake is deprecated)

* Added results for AWS Lightsail

* (typo) in doc (#12099)

* Update polymorphic_parts_l.xml

* Update polymorphic_parts_m.xml

* Update polymorphic_parts_s.xml

* kafka: fix SIGSEGV on DROP TABLE

After #11599 it is possible that messages of the
ReadBufferFromKafkaConsumer will be cleaned-up right in
read_kafka_message callback (from KafkaBlockInputStream) if the stop
flag isset (i.e. DROP TABLE is waiting the consumer), and if
read_kafka_message already processed some rows it will not return 0 and
the loop after will try to get current topic from the buffer, which uses
messages in the underlying and this will got SIGSEGV:

    12:14:56.173262 [ 55421 ] {f7930856-d478-4e41-af56-24ce7b693e95} <Debug> executeQuery: (from 0.0.0.0:0, user: ) DROP TABLE IF EXISTS data.queue
    12:14:56.173285 [ 55421 ] {f7930856-d478-4e41-af56-24ce7b693e95} <Trace> StorageKafka (newly_queue): Waiting for cleanup
    12:14:56.180016 [ 55390 ] {} <Trace> BaseDaemon: Received signal 11
    12:14:56.180267 [ 4914 ] {} <Fatal> BaseDaemon: ########################################
    12:14:56.181879 [ 4914 ] {} <Fatal> BaseDaemon: (version 20.6.1.1, build id: 4CE0298F08583658) (from thread 55468) (no query) Received signal Segmentation fault (11)
    12:14:56.181900 [ 4914 ] {} <Fatal> BaseDaemon: Address: 0x8 Access: read. Address not mapped to object.
    12:14:56.181909 [ 4914 ] {} <Fatal> BaseDaemon: Stack trace:
    12:14:56.184676 [ 4914 ] {} <Fatal> BaseDaemon: 3. /ch/contrib/cppkafka/include/cppkafka/message.h:111: DB::KafkaBlockInputStream::readImpl() @ 0xe343f1c in /usr/lib/debug/usr/bin/clickhouse
    12:14:56.185553 [ 4914 ] {} <Fatal> BaseDaemon: 4. /ch/contrib/libcxx/include/vector:1003: DB::IBlockInputStream::read() @ 0xd9d95bd in /usr/lib/debug/usr/bin/clickhouse
    12:14:56.188238 [ 4914 ] {} <Fatal> BaseDaemon: 5. /ch/src/DataStreams/copyData.cpp:26: DB::copyData() @ 0xd9f712a in /usr/lib/debug/usr/bin/clickhouse
    12:14:56.188780 [ 4914 ] {} <Fatal> BaseDaemon: 6. /ch/contrib/libcxx/include/vector:1532: DB::StorageKafka::streamToViews() @ 0xe335e73 in /usr/lib/debug/usr/bin/clickhouse
    12:14:56.189331 [ 4914 ] {} <Fatal> BaseDaemon: 7. /ch/src/Storages/Kafka/StorageKafka.cpp:491: DB::StorageKafka::threadFunc() @ 0xe336738 in /usr/lib/debug/usr/bin/clickhouse

55421 thread (shows that it still waiting for deactivation):

    5  std::__1::lock_guard<>::lock_guard () at ../contrib/libcxx/include/__mutex_base:90
    6  DB::BackgroundSchedulePoolTaskInfo::deactivate (this=0x7fc7e4465f20) at ../src/Core/BackgroundSchedulePool.cpp:59
    7  DB::StorageKafka::shutdown (this=0x7fc7e45e4600) at ../contrib/libcxx/include/memory:3821

And just in case thread where read_kafka_message is called:

    0  DB::ReadBufferFromKafkaConsumer::nextImpl (this=0x7fd4901d4118) at ../contrib/libcxx/include/atomic:1491
    1  DB::ReadBuffer::next (this=0x7fd4901d4118) at ../src/IO/ReadBuffer.h:59
    2  DB::ReadBuffer::eof (this=0x7fd4901d4118) at ../src/IO/ReadBuffer.h:81
    3  DB::skipWhitespaceIfAny (buf=...) at ../src/IO/ReadHelpers.h:945
    4  DB::JSONEachRowRowInputFormat::readRow (ext=..., columns=..., this=0x7fd499a7a020) at ../src/Processors/Formats/Impl/JSONEachRowRowInputFormat.cpp:222
    5  DB::JSONEachRowRowInputFormat::readRow (this=0x7fd499a7a020, columns=..., ext=...) at ../src/Processors/Formats/Impl/JSONEachRowRowInputFormat.cpp:218
    6  DB::IRowInputFormat::generate (this=0x7fd499a7a020) at ../src/Processors/Formats/IRowInputFormat.cpp:64
    7  DB::ISource::work (this=0x7fd499a7a020) at ../src/Processors/ISource.cpp:48
    8  DB::KafkaBlockInputStream::<lambda()>::operator()(void) const () at ../contrib/libcxx/include/memory:3826
    9  DB::KafkaBlockInputStream::readImpl (this=0x7fd46e718820) at ../contrib/libcxx/include/new:340

Cc: @filimonov

* kafka: check that the data is still usable after parsing

* kafka: improve logging during engine shutdown

This will help with tracking possible issues, when you need to know was
buffer released or not.

* kafka: avoid superior polling after DROP/DETACH TABLE

Before this patch isStalled() was checked before polledDataUnusable(),
and after DROP TABLE isStalled() == true (although this looks tricky).

* kafka: remove outdated comment

As stated by @filimonov it is not relevant (after #11599)

* Added test.

* Create codeql-analysis.yml

* Tiny fixes

* Create anchore-analysis.yml

* Update polymorphic_parts_s.xml

* Update polymorphic_parts_m.xml

* Update polymorphic_parts_l.xml

* Changelog for 20.5

* Update CHANGELOG.md

* Update README.md

* Fix test (#12088)

* Test for a fixed issue #10668, related to input_format_allow_errors_num in CSV

* Add unbundled mode flag

* Remove LC converting to Arrow.

* Remove LC converting to Arrow.

* Move skip lists to clickhouse-test

* Remove LC converting to Arrow.

* More verbose message about skip

* Make skip-list optional

* Added test.

* Add type column in system.disks

* Update clickhouse-test

* Fix handling dependency of table with ENGINE=Dictionary on dictionary.

* Add test.

* Update 01355_CSV_input_format_allow_errors.sh

* Update CHANGELOG.md

* Added a showcase of minimal Docker image

* Added a comment

* Added a comment

* Added a comment

* Formatting

* contrib/unixodbc-cmake: Fix build when UNBUNDLED

target_compile_definitions may only set INTERFACE properties on IMPORTED targets

* Fix version column in replicated version collapsing merge tree (#12121)

* poco-cmake: Fix Poco::Data::ODBC target when UNBUNDLED

By default IMPORTED target has a scope in the directory in which it is created
and below. This leads to the following issues when building UNBUNDLED:

Target "clickhouse" links to target "Poco::Data::ODBC" but the target was not
found.  Perhaps a find_package() call is missing for an IMPORTED target, or an
ALIAS target is missing?

* Add missed <atomic> include in ProxyListConfiguration

* Improve performace of reading in order of sorting key. (#11696)

* simplify reading in order of sorting key

* add perf test for reading many parts

* Revert "simplify reading in order of sorting key"

This reverts commit 7267d7c.

* add threshold for preliminary merge for reading in order

* better threshold

* limit threads in test

* Do not enable sentry if ENABLE_LIBRARIES is not set

* Fail if curl library was enabled and was not found in case of unbundled build

* Normalize "pid" file handling #3501

* Update StatusFile.cpp

* New ISO8601 year modificators for formatDateTime

* Added a test

* Include libcurl4-openssl-dev into yandex/clickhouse-deb-builder

* Remove harmful code from "geoDistance" #12117

* Update formatDateTime.cpp

* Fix warnings from CodeQL

* Added a test

* Minor modification

* Update libdivide to the latest master

* Replace exit to abort in libdivide

* Fix potential overflow in integer division #12119

* Added a test

* Whitespace

* Added a test for #4211

* Attempt to fix "Arcadia" build

* Rename test

* Update arraySum.cpp

* Make code clearer: use enum instead of `bool internal`.

* Update StorageDictionary.h

* Update StorageDictionary.h

* ILIKE operator (#12125)

* Integrated CachingAllocator into MarkCache

* fixed build errors

* reset func hotfix

* upd: Fixing build

* updated submodules links

* fix 2

* updating grabber allocator proto

* updating lost work

* updating CMake to use concepts

* some other changes to get it building (integration into MarkCache)

* further integration into caches

* updated Async metrics, fixed some build errors

* and some other errors revealing

* added perfect forwarding to some functions

* fix: forward template

* fix: constexpr modifier

* fix: FakePODAllocator missing member func

* updated PODArray constructor taking alloc params

* fix: PODArray overload with n restored

* fix: FakePODAlloc duplicating alloc() func

* added constexpr variable for alloc_tag_t

* split cache values by allocators, provided updates

* fix: memcpy

* fix: constexpr modifier

* fix: noexcept modifier

* fix: alloc_tag_t for PODArray constructor

* fix: PODArray copy ctor with different alloc

* fix: resize() signature

* updating to lastest working master

* syncing with 273267

* first draft version

* fix: update Searcher to case-insensitive

* added ILIKE test

* fixed style errors, updated test, split like and ilike,  added notILike

* replaced inconsistent comments

* fixed show tables ilike

* updated missing test cases

* regenerated ya.make

* Update 01355_ilike.sql

Co-authored-by: myrrc <[email protected]>
Co-authored-by: alexey-milovidov <[email protected]>

* add parseDateTimeBestEffortUS function (#12028)

* add function parseDateTimeBestEffortUS
* add test
* add doc

Co-authored-by: alexey-milovidov <[email protected]>

* Cleanup changelog (half done). Now it is acceptable #12104

* Cleanup changelog (half done). Now it is more acceptable #12104

* Cleanup changelog (half done). Now it is more acceptable #12104

* Cleanup changelog (half done). Additions requested by @filimonov #12104

* Remove underscore as word-break character. This partially reverts #11975

* Fix bad test number

* Added a test

* Change exception code from LOGICAL_ERROR to BAD_ARGUMENTS when the name of remote table is empty

* fix segfault with -StateResample combinators

* Fix bad code in redundant ORDER BY optimization #10067

* Add a test

* Fix error

* Autocomplete does not have to work in "Unbundled" build

* Whitespace

* Style

* Test for issue #9088

ALTER DELETE unexpectedly deletes NULL rows

* Remove unused potentially dangerous function

* Fix mutations interpreter #9088

* Added a test

* Added another test just in case

* Added yet another test just in case

* Update 01358_mutation_delete_null_rows.sql

* Fix test

* Fix flaky test

* [anchore] more detailed Dockerfile scan reports (#12159)

* Update array-functions.md (#12130)

修改编码错误

* Update array-functions.md (#12129)

修改编码错误

* [docs] improve redirects destination

* Update SECURITY.md (#12161)

Co-authored-by: Alexey Milovidov <[email protected]>
Co-authored-by: Alexander Tokmakov <[email protected]>
Co-authored-by: kssenii <[email protected]>
Co-authored-by: Alexander Kuzmenkov <[email protected]>
Co-authored-by: Alexander Kuzmenkov <[email protected]>
Co-authored-by: chengy8934 <[email protected]>
Co-authored-by: Ivan Blinkov <[email protected]>
Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
Co-authored-by: Azat Khuzhin <[email protected]>
Co-authored-by: MicrochipQ <[email protected]>
Co-authored-by: Vitaly Baranov <[email protected]>
Co-authored-by: Nikolai Kochetov <[email protected]>
Co-authored-by: alesapin <[email protected]>
Co-authored-by: Artem Zuikov <[email protected]>
Co-authored-by: Alexander Kazakov <[email protected]>
Co-authored-by: Vladimir Chebotarev <[email protected]>
Co-authored-by: Nicolae Vartolomei <[email protected]>
Co-authored-by: filimonov <[email protected]>
Co-authored-by: BayoNet <[email protected]>
Co-authored-by: olgarev <[email protected]>
Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: AsiaKorushkina <[email protected]>
Co-authored-by: asiana21 <[email protected]>
Co-authored-by: BohuTANG <[email protected]>
Co-authored-by: zhang2014 <[email protected]>
Co-authored-by: Evgenia Sudarikova <[email protected]>
Co-authored-by: Anton Popov <[email protected]>
Co-authored-by: manmitya <[email protected]>
Co-authored-by: Nikolai Kochetov <[email protected]>
Co-authored-by: Mikhail Filimonov <[email protected]>
Co-authored-by: Anton Ivashkin <[email protected]>
Co-authored-by: Ilya Yatsishin <[email protected]>
Co-authored-by: tavplubix <[email protected]>
Co-authored-by: Matwey V. Kornilov <[email protected]>
Co-authored-by: vivarum <[email protected]>
Co-authored-by: myrrc <[email protected]>
Co-authored-by: myrrc <[email protected]>
Co-authored-by: flynn <[email protected]>
Co-authored-by: yhgcn <[email protected]>
Co-authored-by: Nikita Mikhaylov <[email protected]>
alexey-milovidov added a commit that referenced this pull request Jul 7, 2020
…ion (#12252)

* Automated backporting machinery (#12029)

* Add automated cherry-pick machinery

* Added script for backporting machinery

* Implement dry-run mode

* Comment old methods

* Fix python2

* Add ya.make for sandbox tasks

* Remove old stuff

* Move writing to RabbitMQ into background task

* Add TLB misses perf counters.

* Update ThreadProfileEvents.cpp

* Fake change in dockerfile

* Fix tuple nullable comparison.

* Fix access rights: cannot grant INTROSPECTION when allow_introspection_functions=0.

* fixup

* Update ThreadProfileEvents.cpp

* Fix test.

* Added test.

* Fix and simplify code

* Fix test.

* Update ITransformingStep.h

* Fix "Sharding key is not deterministic" message

* Do not check *optimize_skip_unused_shards_nesting w/o *optimize_skip_unused_shards

This will avoid supperior log message in case of
*optimize_skip_unused_shards_nesting already disables it.
And also it is logical.

* Fix function if with FixedString arguments of different sizes

* Add multiIf

* Fix error

* Remove test that is not supported by "Arcadia" build system

* Fix constraints check for constant columns

* Make topK return Enum for Enum types

* parse metadata in parallel when loading tables

* Fix error

* Fix build

* fixup

* Update ThreadProfileEvents.cpp

* Update browse-code.md (#12047)

* Update browse-code.md

纠正了一些翻译错误。

* Update browse-code.md

Co-authored-by: Ivan Blinkov <[email protected]>

* Bump python-slugify from 1.2.6 to 4.0.1 in /docs/tools

Bumps [python-slugify](https://github.com/un33k/python-slugify) from 1.2.6 to 4.0.1.
- [Release notes](https://github.com/un33k/python-slugify/releases)
- [Changelog](https://github.com/un33k/python-slugify/blob/master/CHANGELOG.md)
- [Commits](un33k/python-slugify@1.2.6...4.0.1)

Signed-off-by: dependabot-preview[bot] <[email protected]>

* Update ThreadProfileEvents.cpp

* Update README.md

* Fix typo (#12046)

* Fix test_allow_introspection.

* Try fix labda tuple(LC) argument.

* Test image changes

* Try fix labda tuple(LC) argument.

* Add pvs studio to images

* Added test.

* fix low card types in merge join (#12035)

* Update contrib/poco to ClickHouse-Extras/poco #22 (#12037)

* Updated ClickHouse-Extras/poco #22

* Fix defaultValueOfArgumentType

* Added test.

* Update cpu_synthetic.xml

* Moves task shall be started if new storage policy needs them.

* Added test for automatic start of background move task.

* Add ability to run any image version from packager and runner

* Check type of filter for prewhere.

* Check type of filter for prewhere.

* Check type of filter for prewhere.

* Check type of filter for prewhere.

* Added test.

* Try fix pk in tuple performance

Possible approach for fixing #10574

The problem is that prepared sets are built correctly, it is a hash map of key -> set
where key is a hash of AST and list of data types (when we a list of
tuples of literals).

However, when the key is built from the index to try and find if there
exists a prepared set that would match it looks for data types of the
primary key (see how data_types is populated) because the primary key
has only one field (v in my example) it can not find the prepared set.

The patch looks for any prepared indexes where data types match for the
subset of fields found in primary key, we are not interested in other
fields anyway for the purpose of primary key pruning.

* Fix partial revokes (complex cases).

* Changelog for 20.3.11, 12

* simple changelog script

* bump CI

* Fix tests.

* Add explicit test for a case where AST hashes collide for different prepared sets

* [blog] add RSS feed (#12064)

* [blog] add rss feed

* better title

* Update CHANGELOG.md

Co-authored-by: Ivan Blinkov <[email protected]>

* bump ci

* Moved useless S3 logging to TRACE level.

* Add a test to cover non-const tuple elemenets (just in case)

* Bump

* Update query-complexity.md

Remove a note about read limits applied on threads level.

* Update query-complexity.md

* Update query-complexity.md

* Update query-complexity.md

* DOCS-609: max_server_memory_usage (#11771)

* Revolg DOCSUP-1000 add max server memory usage setting (#125)

* Add max_server_memory_usage setting, delete max_memory_usage_for_all_queries setting.

* Syntax fixed

* Apply suggestions from code review

Co-authored-by: BayoNet <[email protected]>

* Doc for the max_server_memory_usage setting. Updates.

Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-609: Minor fixes.

* CLICKHOUSEDOCS-609: Actualized position of the setting.

Co-authored-by: olgarev <[email protected]>
Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>

* Add force_primary_key to a pk in tuple test

* DOCS-510: runningAccumulate (#12061)

* asiana21-DOCSUP-797 (#117)

* docs(runningAccumulate): the function description is added

* docs(runningAccumulate): the function description is modified

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* docs(runningAccumulate): some changes

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* docs(runningAccumulate): added ru translation

Co-authored-by: asiana21 <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-510: Minor fix.

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: Ivan Blinkov <[email protected]>

* CLICKHOUSEDOCS-510: Fixed links.

Co-authored-by: AsiaKorushkina <[email protected]>
Co-authored-by: asiana21 <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Ivan Blinkov <[email protected]>

* Remove const specifier to allow auto-move (clangtidy)

* Rewrite Set lookup to make it more readable

* [docs] Sync zh/development/build-osx.md from EN (#12071)

* ISSUES-4006 support first for ALTER ADD|MODIFY COLUMN

* Update deb image

* Don't download image twice

* Remove garbage from images

* bump ci

* Changelog for 20.1, 20.4

* fixup

* DOCS-635: Translated the EN version of the AvroConfluent format description (#11930)

* DOCSUP-1350 (#128)

* edited EN version

* add EN and RU translation

* minor changes

* CLICKHOUSEDOCS-635: Updated the description.

Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Evgenia Sudarikova <[email protected]>

* Fix tests.

* Better PVS image

* DOCS-605: Description for the always_fetch_merged_part setting (#11921)

* Revolg DOCSUP-998 Document the always_fetch_merged_part setting (#123)

* Add always_fetch_merged_part setting

* revolg-DOCSUP-998-add_always_fetch_merged_part_setting link fixed

* Apply suggestions from code review

Co-authored-by: BayoNet <[email protected]>

* Add always_fetch_merged_part setting. Updates.

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* Add always_fetch_merged_part setting. Updates.

Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-605: Minor fixes.

* CLICKHOUSEDOCS-605: Added Plausible to Adopters.

* Update docs/ru/operations/settings/settings.md

Co-authored-by: alesapin <[email protected]>

* Update docs/en/operations/settings/settings.md

Co-authored-by: alesapin <[email protected]>

* CLICKHOUSEDOCS-605: Fixed access rights description.

Co-authored-by: olgarev <[email protected]>
Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: alesapin <[email protected]>

* Update Dockerfile

* revert e9d3c48

* [blog] 'Package Repository Behind CDN' post (#12082)

* support iframes from DataLens

* initial blog post text

* Improve REVOKE command: now it requires only grant/admin option for only
access which will be revoked.
REVOKE ALL FROM user1 now revokes all granted roles.

* Fix limiting the number of threads for VIEW.

* Update tips.md

* Added test.

* Remove pvs studio from images list

* Better shutdown and conversion

* Reverse arguments

* Fix result_rows and result_bytes metrics for selects.

* Fix result_rows and result_bytes metrics for selects.

* improve breadcrumbs markup

* Fix tests.

* fix segfault with -StateResample combinators

* Less race conditions

* [docker] install ca-certificates before the first apt-get update (#12095)

* [docker] install ca-certificates before first apt-get update

* Update Dockerfile

* DOCS-522: max_parser_depth (#12097)

* asiana21-DOCSUP-925-max_parser_depth (#132)

* docs(max_parser_depth): added the setting description

* docs(max_parser_depth): some changes

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* docs(max_parser_depth): added ru translation

* docs(max_parser_depth): removed quotation marks

Co-authored-by: asiana21 <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-522: Fixed the link.

Co-authored-by: AsiaKorushkina <[email protected]>
Co-authored-by: asiana21 <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>

* Rewrite curl dependency in a more ch compatible way

- add support of unbundled curl
- add CURL::libcurl libraries
- avoid explicit linkage of daemon with curl (added with sentry)
- set CACHE variables for non-direct users:
  - mariadb-connector-c
  - aws-s3-cmake
  - sentry-native

Cc: @alexey-milovidov
Cc: @alesapin (requires docker image update)
Cc: @abyss7

Refs: #11300
Refs: #8011
Refs: #8905

v2: replace cmake/find/curl.cmake with proper contrib/curl-cmake (as
pointed by @abyss7, cmake/find/*.cmake is deprecated)

* Added results for AWS Lightsail

* (typo) in doc (#12099)

* Added test.

* Create codeql-analysis.yml

* Tiny fixes

* Create anchore-analysis.yml

* Changelog for 20.5

* Update CHANGELOG.md

* Update README.md

* Fix test (#12088)

* Test for a fixed issue #10668, related to input_format_allow_errors_num in CSV

* Add unbundled mode flag

* Remove LC converting to Arrow.

* Remove LC converting to Arrow.

* Move skip lists to clickhouse-test

* Remove LC converting to Arrow.

* More verbose message about skip

* Make skip-list optional

* Added test.

* Add type column in system.disks

* Update clickhouse-test

* Fix handling dependency of table with ENGINE=Dictionary on dictionary.

* Add test.

* Update 01355_CSV_input_format_allow_errors.sh

* Update CHANGELOG.md

* Added a showcase of minimal Docker image

* Added a comment

* Added a comment

* Added a comment

* Formatting

* contrib/unixodbc-cmake: Fix build when UNBUNDLED

target_compile_definitions may only set INTERFACE properties on IMPORTED targets

* Fix version column in replicated version collapsing merge tree (#12121)

* poco-cmake: Fix Poco::Data::ODBC target when UNBUNDLED

By default IMPORTED target has a scope in the directory in which it is created
and below. This leads to the following issues when building UNBUNDLED:

Target "clickhouse" links to target "Poco::Data::ODBC" but the target was not
found.  Perhaps a find_package() call is missing for an IMPORTED target, or an
ALIAS target is missing?

* Add missed <atomic> include in ProxyListConfiguration

* Improve performace of reading in order of sorting key. (#11696)

* simplify reading in order of sorting key

* add perf test for reading many parts

* Revert "simplify reading in order of sorting key"

This reverts commit 7267d7c.

* add threshold for preliminary merge for reading in order

* better threshold

* limit threads in test

* Do not enable sentry if ENABLE_LIBRARIES is not set

* Fail if curl library was enabled and was not found in case of unbundled build

* Normalize "pid" file handling #3501

* Update StatusFile.cpp

* New ISO8601 year modificators for formatDateTime

* Added a test

* Include libcurl4-openssl-dev into yandex/clickhouse-deb-builder

* Remove harmful code from "geoDistance" #12117

* Update formatDateTime.cpp

* Fix warnings from CodeQL

* Added a test

* Minor modification

* Update libdivide to the latest master

* Replace exit to abort in libdivide

* Fix potential overflow in integer division #12119

* Added a test

* Whitespace

* Added a test for #4211

* Attempt to fix "Arcadia" build

* Rename test

* Update arraySum.cpp

* Make code clearer: use enum instead of `bool internal`.

* Update StorageDictionary.h

* Update StorageDictionary.h

* ILIKE operator (#12125)

* Integrated CachingAllocator into MarkCache

* fixed build errors

* reset func hotfix

* upd: Fixing build

* updated submodules links

* fix 2

* updating grabber allocator proto

* updating lost work

* updating CMake to use concepts

* some other changes to get it building (integration into MarkCache)

* further integration into caches

* updated Async metrics, fixed some build errors

* and some other errors revealing

* added perfect forwarding to some functions

* fix: forward template

* fix: constexpr modifier

* fix: FakePODAllocator missing member func

* updated PODArray constructor taking alloc params

* fix: PODArray overload with n restored

* fix: FakePODAlloc duplicating alloc() func

* added constexpr variable for alloc_tag_t

* split cache values by allocators, provided updates

* fix: memcpy

* fix: constexpr modifier

* fix: noexcept modifier

* fix: alloc_tag_t for PODArray constructor

* fix: PODArray copy ctor with different alloc

* fix: resize() signature

* updating to lastest working master

* syncing with 273267

* first draft version

* fix: update Searcher to case-insensitive

* added ILIKE test

* fixed style errors, updated test, split like and ilike,  added notILike

* replaced inconsistent comments

* fixed show tables ilike

* updated missing test cases

* regenerated ya.make

* Update 01355_ilike.sql

Co-authored-by: myrrc <[email protected]>
Co-authored-by: alexey-milovidov <[email protected]>

* add parseDateTimeBestEffortUS function (#12028)

* add function parseDateTimeBestEffortUS
* add test
* add doc

Co-authored-by: alexey-milovidov <[email protected]>

* Cleanup changelog (half done). Now it is acceptable #12104

* Cleanup changelog (half done). Now it is more acceptable #12104

* Cleanup changelog (half done). Now it is more acceptable #12104

* Cleanup changelog (half done). Additions requested by @filimonov #12104

* Remove underscore as word-break character. This partially reverts #11975

* Fix bad test number

* Added a test

* Change exception code from LOGICAL_ERROR to BAD_ARGUMENTS when the name of remote table is empty

* fix segfault with -StateResample combinators

* Fix bad code in redundant ORDER BY optimization #10067

* Add a test

* Fix error

* Autocomplete does not have to work in "Unbundled" build

* Whitespace

* Style

* Fix flaky test

Co-authored-by: Ivan <[email protected]>
Co-authored-by: Vitaly Baranov <[email protected]>
Co-authored-by: kssenii <[email protected]>
Co-authored-by: Alexander Kuzmenkov <[email protected]>
Co-authored-by: Alexander Kuzmenkov <[email protected]>
Co-authored-by: alesapin <[email protected]>
Co-authored-by: Nikolai Kochetov <[email protected]>
Co-authored-by: alexey-milovidov <[email protected]>
Co-authored-by: Nikita Mikhaylov <[email protected]>
Co-authored-by: Azat Khuzhin <[email protected]>
Co-authored-by: Alexander Tokmakov <[email protected]>
Co-authored-by: chengy8934 <[email protected]>
Co-authored-by: Ivan Blinkov <[email protected]>
Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
Co-authored-by: MicrochipQ <[email protected]>
Co-authored-by: Artem Zuikov <[email protected]>
Co-authored-by: Alexander Kazakov <[email protected]>
Co-authored-by: Vladimir Chebotarev <[email protected]>
Co-authored-by: Nicolae Vartolomei <[email protected]>
Co-authored-by: filimonov <[email protected]>
Co-authored-by: BayoNet <[email protected]>
Co-authored-by: olgarev <[email protected]>
Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: AsiaKorushkina <[email protected]>
Co-authored-by: asiana21 <[email protected]>
Co-authored-by: BohuTANG <[email protected]>
Co-authored-by: zhang2014 <[email protected]>
Co-authored-by: Evgenia Sudarikova <[email protected]>
Co-authored-by: Anton Popov <[email protected]>
Co-authored-by: manmitya <[email protected]>
Co-authored-by: Nikolai Kochetov <[email protected]>
Co-authored-by: Mikhail Filimonov <[email protected]>
Co-authored-by: Anton Ivashkin <[email protected]>
Co-authored-by: Ilya Yatsishin <[email protected]>
Co-authored-by: tavplubix <[email protected]>
Co-authored-by: Matwey V. Kornilov <[email protected]>
Co-authored-by: vivarum <[email protected]>
Co-authored-by: myrrc <[email protected]>
Co-authored-by: myrrc <[email protected]>
Co-authored-by: flynn <[email protected]>
alexey-milovidov added a commit that referenced this pull request Jul 7, 2020
* Make it more correct

* Add a test

* Avoid floating point error in geohashesInBox #11369

* Avro: allow missing fields

* update

* Fix build

* Revert "[experiment] maybe fix warnings in integration tests"

* Add xeus-clickhouse (#12010)

xeus-clickhouse is a Jupyter kernal for ClickHouse

* Fix test

* Fix array size overflow in generateRandom

* Added a test

* Update ErrorCodes.cpp

* More hardening

* More hardening

* Move reading from RabbitMQ into background task

* Fix access rights: cannot grant DDL when allow_ddl=0

* Add tests

* Add test test_allow_ddl.

* Added failing test

* Remove the usage of obsolete setting

* Whitespace

* Added a test

* Allow to ALTER partition key in some cases

* Slightly more safe

* Only allow Enum extension within the same width

* Update test

* Added failing test for Replicated table

* Fix clang-tidy

* Whitespace

* Write partition key changes to ZooKeeper

* Typos

* Implement for ReplicatedMergeTree

* Added test reference

* Added missing ORDER BY in test

* Fix integration test

* Fix error in addMonths with floating point argument

* Fix error in addMonths with floating point argument

* Fix overflow in function "neighbor"

* Whitespace

* Whitespace

* Fix ORDER BY tuple with COLLATE on const column

* clickhouse-local: logging flags fixes

* clickhouse-local: use std::filesystem::equivalent

* Limit /proc/cpuinfo metrics to linux only

* Feature 8074 (#12014)

* refs #8074 1: start to stream

* refs final check format and spell

* refs final check format and spell

* refs #8074 fix up link to sql-reference/functions/other-functions

* Bump idna from 2.9 to 2.10 in /docs/tools

Bumps [idna](https://github.com/kjd/idna) from 2.9 to 2.10.
- [Release notes](https://github.com/kjd/idna/releases)
- [Changelog](https://github.com/kjd/idna/blob/master/HISTORY.rst)
- [Commits](kjd/idna@v2.9...v2.10)

Signed-off-by: dependabot-preview[bot] <[email protected]>

* make a short test for DateTime

* Fixup

* DOCS-636 Synchronized some edits from EN to RU (#11941)

* [review][clickhousedocs][translate] DOCSUP-1351: Edit and translate to Russian (#129)

* DOCSUP-1351: Add blockSerializedSize (RU)

* DOCSUP-1351: Fix blockSerializedSize description by function description template.

* DOCSUP-1351: PR8756- Update Distributed engine section.

* DOCSUP-1351: PR9076-Show Queries more like MySQL did.

* DOCSUP-1351: PR#9919-system.tables improvements (total_rows/total_bytes/storage_policy)

* DOCSUP-1351: (ru) blockSerializedSize remake by template.

* DOCSUP-1351: PR#9598-Add function arrayReduceInRange and update arrayReduce function.

* DOCSUP-1351: PR#9598 Fix arrayReduce and arrayReduceInRanges sections by template.

* DOCSUP-1351: Some fixes.

* DOCSUP-1351: Some fixes.

Co-authored-by: romanzhukov <[email protected]>

* CLICKHOUSEDOCS-636: Minor changes.

Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Roman Bug <[email protected]>
Co-authored-by: romanzhukov <[email protected]>

* Use ConcurentBoundedQueue instead of vector

* Temporary enable debug logs when releasing docs

* Better docker images list

* [docs] improve stable releases discovery

* Update contrib/jemalloc-cmake/CMakeLists.txt

* Remove libevent library

* Automated backporting machinery (#12029)

* Add automated cherry-pick machinery

* Added script for backporting machinery

* Implement dry-run mode

* Comment old methods

* Fix python2

* Add ya.make for sandbox tasks

* Remove old stuff

* Move writing to RabbitMQ into background task

* Add TLB misses perf counters.

* Update ThreadProfileEvents.cpp

* Fake change in dockerfile

* Fix tuple nullable comparison.

* Fix access rights: cannot grant INTROSPECTION when allow_introspection_functions=0.

* fixup

* Update ThreadProfileEvents.cpp

* Fix test.

* Added test.

* Fix and simplify code

* Fix test.

* Update ITransformingStep.h

* Fix "Sharding key is not deterministic" message

* Do not check *optimize_skip_unused_shards_nesting w/o *optimize_skip_unused_shards

This will avoid supperior log message in case of
*optimize_skip_unused_shards_nesting already disables it.
And also it is logical.

* Remove test that is not supported by "Arcadia" build system

* Make topK return Enum for Enum types

* parse metadata in parallel when loading tables

* Fix build

* fixup

* Update ThreadProfileEvents.cpp

* Update browse-code.md (#12047)

* Update browse-code.md

纠正了一些翻译错误。

* Update browse-code.md

Co-authored-by: Ivan Blinkov <[email protected]>

* Bump python-slugify from 1.2.6 to 4.0.1 in /docs/tools

Bumps [python-slugify](https://github.com/un33k/python-slugify) from 1.2.6 to 4.0.1.
- [Release notes](https://github.com/un33k/python-slugify/releases)
- [Changelog](https://github.com/un33k/python-slugify/blob/master/CHANGELOG.md)
- [Commits](un33k/python-slugify@1.2.6...4.0.1)

Signed-off-by: dependabot-preview[bot] <[email protected]>

* Update ThreadProfileEvents.cpp

* Update README.md

* Fix typo (#12046)

* Fix test_allow_introspection.

* Try fix labda tuple(LC) argument.

* Test image changes

* Try fix labda tuple(LC) argument.

* Add pvs studio to images

* Added test.

* fix low card types in merge join (#12035)

* Update contrib/poco to ClickHouse-Extras/poco #22 (#12037)

* Updated ClickHouse-Extras/poco #22

* Fix defaultValueOfArgumentType

* Added test.

* Update cpu_synthetic.xml

* Moves task shall be started if new storage policy needs them.

* Added test for automatic start of background move task.

* Add ability to run any image version from packager and runner

* Check type of filter for prewhere.

* Check type of filter for prewhere.

* Check type of filter for prewhere.

* Check type of filter for prewhere.

* Added test.

* Try fix pk in tuple performance

Possible approach for fixing #10574

The problem is that prepared sets are built correctly, it is a hash map of key -> set
where key is a hash of AST and list of data types (when we a list of
tuples of literals).

However, when the key is built from the index to try and find if there
exists a prepared set that would match it looks for data types of the
primary key (see how data_types is populated) because the primary key
has only one field (v in my example) it can not find the prepared set.

The patch looks for any prepared indexes where data types match for the
subset of fields found in primary key, we are not interested in other
fields anyway for the purpose of primary key pruning.

* Fix partial revokes (complex cases).

* Changelog for 20.3.11, 12

* simple changelog script

* bump CI

* Fix tests.

* Add explicit test for a case where AST hashes collide for different prepared sets

* [blog] add RSS feed (#12064)

* [blog] add rss feed

* better title

* Update CHANGELOG.md

Co-authored-by: Ivan Blinkov <[email protected]>

* bump ci

* Moved useless S3 logging to TRACE level.

* Add a test to cover non-const tuple elemenets (just in case)

* Bump

* Update query-complexity.md

Remove a note about read limits applied on threads level.

* Update query-complexity.md

* Update query-complexity.md

* Update query-complexity.md

* DOCS-609: max_server_memory_usage (#11771)

* Revolg DOCSUP-1000 add max server memory usage setting (#125)

* Add max_server_memory_usage setting, delete max_memory_usage_for_all_queries setting.

* Syntax fixed

* Apply suggestions from code review

Co-authored-by: BayoNet <[email protected]>

* Doc for the max_server_memory_usage setting. Updates.

Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-609: Minor fixes.

* CLICKHOUSEDOCS-609: Actualized position of the setting.

Co-authored-by: olgarev <[email protected]>
Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>

* Add force_primary_key to a pk in tuple test

* DOCS-510: runningAccumulate (#12061)

* asiana21-DOCSUP-797 (#117)

* docs(runningAccumulate): the function description is added

* docs(runningAccumulate): the function description is modified

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* docs(runningAccumulate): some changes

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* docs(runningAccumulate): added ru translation

Co-authored-by: asiana21 <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-510: Minor fix.

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: Ivan Blinkov <[email protected]>

* CLICKHOUSEDOCS-510: Fixed links.

Co-authored-by: AsiaKorushkina <[email protected]>
Co-authored-by: asiana21 <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Ivan Blinkov <[email protected]>

* Remove const specifier to allow auto-move (clangtidy)

* Rewrite Set lookup to make it more readable

* [docs] Sync zh/development/build-osx.md from EN (#12071)

* ISSUES-4006 support first for ALTER ADD|MODIFY COLUMN

* Update deb image

* Don't download image twice

* Remove garbage from images

* bump ci

* fixup

* DOCS-635: Translated the EN version of the AvroConfluent format description (#11930)

* DOCSUP-1350 (#128)

* edited EN version

* add EN and RU translation

* minor changes

* CLICKHOUSEDOCS-635: Updated the description.

Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Evgenia Sudarikova <[email protected]>

* Fix tests.

* Better PVS image

* DOCS-605: Description for the always_fetch_merged_part setting (#11921)

* Revolg DOCSUP-998 Document the always_fetch_merged_part setting (#123)

* Add always_fetch_merged_part setting

* revolg-DOCSUP-998-add_always_fetch_merged_part_setting link fixed

* Apply suggestions from code review

Co-authored-by: BayoNet <[email protected]>

* Add always_fetch_merged_part setting. Updates.

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* Add always_fetch_merged_part setting. Updates.

Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-605: Minor fixes.

* CLICKHOUSEDOCS-605: Added Plausible to Adopters.

* Update docs/ru/operations/settings/settings.md

Co-authored-by: alesapin <[email protected]>

* Update docs/en/operations/settings/settings.md

Co-authored-by: alesapin <[email protected]>

* CLICKHOUSEDOCS-605: Fixed access rights description.

Co-authored-by: olgarev <[email protected]>
Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: alesapin <[email protected]>

* Update Dockerfile

* revert e9d3c48

* [blog] 'Package Repository Behind CDN' post (#12082)

* support iframes from DataLens

* initial blog post text

* Improve REVOKE command: now it requires only grant/admin option for only
access which will be revoked.
REVOKE ALL FROM user1 now revokes all granted roles.

* Fix limiting the number of threads for VIEW.

* Update tips.md

* Added test.

* Remove pvs studio from images list

* Better shutdown and conversion

* Reverse arguments

* Fix result_rows and result_bytes metrics for selects.

* Fix result_rows and result_bytes metrics for selects.

* improve breadcrumbs markup

* Fix tests.

* Less race conditions

* [docker] install ca-certificates before the first apt-get update (#12095)

* [docker] install ca-certificates before first apt-get update

* Update Dockerfile

* DOCS-522: max_parser_depth (#12097)

* asiana21-DOCSUP-925-max_parser_depth (#132)

* docs(max_parser_depth): added the setting description

* docs(max_parser_depth): some changes

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* docs(max_parser_depth): added ru translation

* docs(max_parser_depth): removed quotation marks

Co-authored-by: asiana21 <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-522: Fixed the link.

Co-authored-by: AsiaKorushkina <[email protected]>
Co-authored-by: asiana21 <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>

* Added results for AWS Lightsail

* (typo) in doc (#12099)

* Added test.

* Create codeql-analysis.yml

* Tiny fixes

* Create anchore-analysis.yml

* Update README.md

* Fix test (#12088)

* Test for a fixed issue #10668, related to input_format_allow_errors_num in CSV

* Add unbundled mode flag

* Remove LC converting to Arrow.

* Remove LC converting to Arrow.

* Move skip lists to clickhouse-test

* Remove LC converting to Arrow.

* More verbose message about skip

* Make skip-list optional

* Added test.

* Add type column in system.disks

* Update clickhouse-test

* Update 01355_CSV_input_format_allow_errors.sh

* Added a showcase of minimal Docker image

* Added a comment

* Added a comment

* Added a comment

* Formatting

* contrib/unixodbc-cmake: Fix build when UNBUNDLED

target_compile_definitions may only set INTERFACE properties on IMPORTED targets

* Fix version column in replicated version collapsing merge tree (#12121)

* poco-cmake: Fix Poco::Data::ODBC target when UNBUNDLED

By default IMPORTED target has a scope in the directory in which it is created
and below. This leads to the following issues when building UNBUNDLED:

Target "clickhouse" links to target "Poco::Data::ODBC" but the target was not
found.  Perhaps a find_package() call is missing for an IMPORTED target, or an
ALIAS target is missing?

* Add missed <atomic> include in ProxyListConfiguration

* Improve performace of reading in order of sorting key. (#11696)

* simplify reading in order of sorting key

* add perf test for reading many parts

* Revert "simplify reading in order of sorting key"

This reverts commit 7267d7c.

* add threshold for preliminary merge for reading in order

* better threshold

* limit threads in test

* Normalize "pid" file handling #3501

* Update StatusFile.cpp

* Remove harmful code from "geoDistance" #12117

* Whitespace

Co-authored-by: Alexey Milovidov <[email protected]>
Co-authored-by: Andrew Onyshchuk <[email protected]>
Co-authored-by: feng lv <[email protected]>
Co-authored-by: alesapin <[email protected]>
Co-authored-by: Wang Fenjin <[email protected]>
Co-authored-by: kssenii <[email protected]>
Co-authored-by: Vitaly Baranov <[email protected]>
Co-authored-by: Mikhail Gaidamaka <[email protected]>
Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
Co-authored-by: Alexander Kuzmenkov <[email protected]>
Co-authored-by: Nikolai Kochetov <[email protected]>
Co-authored-by: Ivan Blinkov <[email protected]>
Co-authored-by: BayoNet <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Roman Bug <[email protected]>
Co-authored-by: romanzhukov <[email protected]>
Co-authored-by: tavplubix <[email protected]>
Co-authored-by: Alexander Kuzmenkov <[email protected]>
Co-authored-by: Ivan <[email protected]>
Co-authored-by: Nikita Mikhaylov <[email protected]>
Co-authored-by: Azat Khuzhin <[email protected]>
Co-authored-by: chengy8934 <[email protected]>
Co-authored-by: MicrochipQ <[email protected]>
Co-authored-by: Artem Zuikov <[email protected]>
Co-authored-by: Alexander Kazakov <[email protected]>
Co-authored-by: Vladimir Chebotarev <[email protected]>
Co-authored-by: Nicolae Vartolomei <[email protected]>
Co-authored-by: filimonov <[email protected]>
Co-authored-by: olgarev <[email protected]>
Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: AsiaKorushkina <[email protected]>
Co-authored-by: asiana21 <[email protected]>
Co-authored-by: BohuTANG <[email protected]>
Co-authored-by: zhang2014 <[email protected]>
Co-authored-by: Evgenia Sudarikova <[email protected]>
Co-authored-by: Anton Popov <[email protected]>
Co-authored-by: manmitya <[email protected]>
Co-authored-by: Nikolai Kochetov <[email protected]>
Co-authored-by: Mikhail Filimonov <[email protected]>
Co-authored-by: Anton Ivashkin <[email protected]>
Co-authored-by: Ilya Yatsishin <[email protected]>
Co-authored-by: tavplubix <[email protected]>
Co-authored-by: Matwey V. Kornilov <[email protected]>
alexey-milovidov added a commit that referenced this pull request Jul 7, 2020
* Update replxx submodule

* Add a test for #10102

* disable tests in arcadia

* Added a test from #5131

* Try to enable long perf tests

* perf test: report queries with new functions separately

* performance comparison

* longer

* muzzy decay 10 ms

* Support Enums type for MySQL engine #3985

* performance comparison

* Add integration test for MySQL enums type

* Fix bad log message at server startup

* Insert enum column values for test

* Better diagnostics of "Replica {} appears to be already active" message

* Fix typos

* Added a test for #8550

* Update extended-roadmap.md

* Update test

* Fix FPE, step 1

* Make it more correct

* Add a test

* Avoid floating point error in geohashesInBox #11369

* Avro: allow missing fields

* update

* Fix build

* Revert "[experiment] maybe fix warnings in integration tests"

* Add xeus-clickhouse (#12010)

xeus-clickhouse is a Jupyter kernal for ClickHouse

* Fix test

* Fix array size overflow in generateRandom

* Added a test

* Update ErrorCodes.cpp

* More hardening

* More hardening

* Move reading from RabbitMQ into background task

* Fix access rights: cannot grant DDL when allow_ddl=0

* Add tests

* Add test test_allow_ddl.

* Added failing test

* Remove the usage of obsolete setting

* Whitespace

* Added a test

* Allow to ALTER partition key in some cases

* Slightly more safe

* Only allow Enum extension within the same width

* Update test

* Added failing test for Replicated table

* Fix clang-tidy

* Whitespace

* Write partition key changes to ZooKeeper

* Typos

* Implement for ReplicatedMergeTree

* Added test reference

* Added missing ORDER BY in test

* Fix integration test

* Fix error in addMonths with floating point argument

* Fix error in addMonths with floating point argument

* Fix overflow in function "neighbor"

* Whitespace

* Whitespace

* Fix ORDER BY tuple with COLLATE on const column

* clickhouse-local: logging flags fixes

* clickhouse-local: use std::filesystem::equivalent

* Limit /proc/cpuinfo metrics to linux only

* Feature 8074 (#12014)

* refs #8074 1: start to stream

* refs final check format and spell

* refs final check format and spell

* refs #8074 fix up link to sql-reference/functions/other-functions

* Bump idna from 2.9 to 2.10 in /docs/tools

Bumps [idna](https://github.com/kjd/idna) from 2.9 to 2.10.
- [Release notes](https://github.com/kjd/idna/releases)
- [Changelog](https://github.com/kjd/idna/blob/master/HISTORY.rst)
- [Commits](kjd/idna@v2.9...v2.10)

Signed-off-by: dependabot-preview[bot] <[email protected]>

* make a short test for DateTime

* Fixup

* DOCS-636 Synchronized some edits from EN to RU (#11941)

* [review][clickhousedocs][translate] DOCSUP-1351: Edit and translate to Russian (#129)

* DOCSUP-1351: Add blockSerializedSize (RU)

* DOCSUP-1351: Fix blockSerializedSize description by function description template.

* DOCSUP-1351: PR8756- Update Distributed engine section.

* DOCSUP-1351: PR9076-Show Queries more like MySQL did.

* DOCSUP-1351: PR#9919-system.tables improvements (total_rows/total_bytes/storage_policy)

* DOCSUP-1351: (ru) blockSerializedSize remake by template.

* DOCSUP-1351: PR#9598-Add function arrayReduceInRange and update arrayReduce function.

* DOCSUP-1351: PR#9598 Fix arrayReduce and arrayReduceInRanges sections by template.

* DOCSUP-1351: Some fixes.

* DOCSUP-1351: Some fixes.

Co-authored-by: romanzhukov <[email protected]>

* CLICKHOUSEDOCS-636: Minor changes.

Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Roman Bug <[email protected]>
Co-authored-by: romanzhukov <[email protected]>

* Use ConcurentBoundedQueue instead of vector

* Temporary enable debug logs when releasing docs

* Better docker images list

* [docs] improve stable releases discovery

* Update contrib/jemalloc-cmake/CMakeLists.txt

* Remove libevent library

* Automated backporting machinery (#12029)

* Add automated cherry-pick machinery

* Added script for backporting machinery

* Implement dry-run mode

* Comment old methods

* Fix python2

* Add ya.make for sandbox tasks

* Remove old stuff

* Move writing to RabbitMQ into background task

* Add TLB misses perf counters.

* Update ThreadProfileEvents.cpp

* Fake change in dockerfile

* Fix tuple nullable comparison.

* Fix access rights: cannot grant INTROSPECTION when allow_introspection_functions=0.

* fixup

* Update ThreadProfileEvents.cpp

* Fix test.

* Added test.

* Fix and simplify code

* Fix test.

* Update ITransformingStep.h

* Fix "Sharding key is not deterministic" message

* Do not check *optimize_skip_unused_shards_nesting w/o *optimize_skip_unused_shards

This will avoid supperior log message in case of
*optimize_skip_unused_shards_nesting already disables it.
And also it is logical.

* Remove test that is not supported by "Arcadia" build system

* Make topK return Enum for Enum types

* parse metadata in parallel when loading tables

* Fix build

* fixup

* Update ThreadProfileEvents.cpp

* Update browse-code.md (#12047)

* Update browse-code.md

纠正了一些翻译错误。

* Update browse-code.md

Co-authored-by: Ivan Blinkov <[email protected]>

* Bump python-slugify from 1.2.6 to 4.0.1 in /docs/tools

Bumps [python-slugify](https://github.com/un33k/python-slugify) from 1.2.6 to 4.0.1.
- [Release notes](https://github.com/un33k/python-slugify/releases)
- [Changelog](https://github.com/un33k/python-slugify/blob/master/CHANGELOG.md)
- [Commits](un33k/python-slugify@1.2.6...4.0.1)

Signed-off-by: dependabot-preview[bot] <[email protected]>

* Update ThreadProfileEvents.cpp

* Update README.md

* Fix typo (#12046)

* Fix test_allow_introspection.

* Try fix labda tuple(LC) argument.

* Test image changes

* Try fix labda tuple(LC) argument.

* Add pvs studio to images

* Added test.

* fix low card types in merge join (#12035)

* Update contrib/poco to ClickHouse-Extras/poco #22 (#12037)

* Updated ClickHouse-Extras/poco #22

* Fix defaultValueOfArgumentType

* Added test.

* Update cpu_synthetic.xml

* Moves task shall be started if new storage policy needs them.

* Added test for automatic start of background move task.

* Add ability to run any image version from packager and runner

* Try fix pk in tuple performance

Possible approach for fixing #10574

The problem is that prepared sets are built correctly, it is a hash map of key -> set
where key is a hash of AST and list of data types (when we a list of
tuples of literals).

However, when the key is built from the index to try and find if there
exists a prepared set that would match it looks for data types of the
primary key (see how data_types is populated) because the primary key
has only one field (v in my example) it can not find the prepared set.

The patch looks for any prepared indexes where data types match for the
subset of fields found in primary key, we are not interested in other
fields anyway for the purpose of primary key pruning.

* Fix partial revokes (complex cases).

* Changelog for 20.3.11, 12

* simple changelog script

* bump CI

* Add explicit test for a case where AST hashes collide for different prepared sets

* [blog] add RSS feed (#12064)

* [blog] add rss feed

* better title

* Update CHANGELOG.md

Co-authored-by: Ivan Blinkov <[email protected]>

* bump ci

* Moved useless S3 logging to TRACE level.

* Add a test to cover non-const tuple elemenets (just in case)

* Bump

* Update query-complexity.md

Remove a note about read limits applied on threads level.

* Update query-complexity.md

* Update query-complexity.md

* Update query-complexity.md

* DOCS-609: max_server_memory_usage (#11771)

* Revolg DOCSUP-1000 add max server memory usage setting (#125)

* Add max_server_memory_usage setting, delete max_memory_usage_for_all_queries setting.

* Syntax fixed

* Apply suggestions from code review

Co-authored-by: BayoNet <[email protected]>

* Doc for the max_server_memory_usage setting. Updates.

Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-609: Minor fixes.

* CLICKHOUSEDOCS-609: Actualized position of the setting.

Co-authored-by: olgarev <[email protected]>
Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>

* Add force_primary_key to a pk in tuple test

* DOCS-510: runningAccumulate (#12061)

* asiana21-DOCSUP-797 (#117)

* docs(runningAccumulate): the function description is added

* docs(runningAccumulate): the function description is modified

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* docs(runningAccumulate): some changes

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* docs(runningAccumulate): added ru translation

Co-authored-by: asiana21 <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-510: Minor fix.

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: Ivan Blinkov <[email protected]>

* CLICKHOUSEDOCS-510: Fixed links.

Co-authored-by: AsiaKorushkina <[email protected]>
Co-authored-by: asiana21 <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Ivan Blinkov <[email protected]>

* Remove const specifier to allow auto-move (clangtidy)

* Rewrite Set lookup to make it more readable

* [docs] Sync zh/development/build-osx.md from EN (#12071)

* ISSUES-4006 support first for ALTER ADD|MODIFY COLUMN

* Update deb image

* Don't download image twice

* Remove garbage from images

* bump ci

* fixup

* DOCS-635: Translated the EN version of the AvroConfluent format description (#11930)

* DOCSUP-1350 (#128)

* edited EN version

* add EN and RU translation

* minor changes

* CLICKHOUSEDOCS-635: Updated the description.

Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Evgenia Sudarikova <[email protected]>

* Better PVS image

* DOCS-605: Description for the always_fetch_merged_part setting (#11921)

* Revolg DOCSUP-998 Document the always_fetch_merged_part setting (#123)

* Add always_fetch_merged_part setting

* revolg-DOCSUP-998-add_always_fetch_merged_part_setting link fixed

* Apply suggestions from code review

Co-authored-by: BayoNet <[email protected]>

* Add always_fetch_merged_part setting. Updates.

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* Add always_fetch_merged_part setting. Updates.

Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-605: Minor fixes.

* CLICKHOUSEDOCS-605: Added Plausible to Adopters.

* Update docs/ru/operations/settings/settings.md

Co-authored-by: alesapin <[email protected]>

* Update docs/en/operations/settings/settings.md

Co-authored-by: alesapin <[email protected]>

* CLICKHOUSEDOCS-605: Fixed access rights description.

Co-authored-by: olgarev <[email protected]>
Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: alesapin <[email protected]>

* Update Dockerfile

* revert e9d3c48

* [blog] 'Package Repository Behind CDN' post (#12082)

* support iframes from DataLens

* initial blog post text

* Improve REVOKE command: now it requires only grant/admin option for only
access which will be revoked.
REVOKE ALL FROM user1 now revokes all granted roles.

* Fix limiting the number of threads for VIEW.

* Update tips.md

* Added test.

* Remove pvs studio from images list

* Better shutdown and conversion

* Reverse arguments

* improve breadcrumbs markup

* Less race conditions

* [docker] install ca-certificates before the first apt-get update (#12095)

* [docker] install ca-certificates before first apt-get update

* Update Dockerfile

* DOCS-522: max_parser_depth (#12097)

* asiana21-DOCSUP-925-max_parser_depth (#132)

* docs(max_parser_depth): added the setting description

* docs(max_parser_depth): some changes

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* docs(max_parser_depth): added ru translation

* docs(max_parser_depth): removed quotation marks

Co-authored-by: asiana21 <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-522: Fixed the link.

Co-authored-by: AsiaKorushkina <[email protected]>
Co-authored-by: asiana21 <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>

* Added results for AWS Lightsail

* (typo) in doc (#12099)

* Create codeql-analysis.yml

* Tiny fixes

* Create anchore-analysis.yml

* Update README.md

* Fix test (#12088)

* Test for a fixed issue #10668, related to input_format_allow_errors_num in CSV

* Add unbundled mode flag

* Move skip lists to clickhouse-test

* More verbose message about skip

* Make skip-list optional

* Update clickhouse-test

* Update 01355_CSV_input_format_allow_errors.sh

* Added a showcase of minimal Docker image

* Added a comment

* Added a comment

* Added a comment

* Formatting

* Fix version column in replicated version collapsing merge tree (#12121)

* Improve performace of reading in order of sorting key. (#11696)

* simplify reading in order of sorting key

* add perf test for reading many parts

* Revert "simplify reading in order of sorting key"

This reverts commit 7267d7c.

* add threshold for preliminary merge for reading in order

* better threshold

* limit threads in test

* Normalize "pid" file handling #3501

* Update StatusFile.cpp

Co-authored-by: Andrew Onyshchuk <[email protected]>
Co-authored-by: Alexey Milovidov <[email protected]>
Co-authored-by: Nikita Mikhaylov <[email protected]>
Co-authored-by: Alexander Kuzmenkov <[email protected]>
Co-authored-by: BohuTANG <[email protected]>
Co-authored-by: feng lv <[email protected]>
Co-authored-by: alesapin <[email protected]>
Co-authored-by: Wang Fenjin <[email protected]>
Co-authored-by: kssenii <[email protected]>
Co-authored-by: Vitaly Baranov <[email protected]>
Co-authored-by: Mikhail Gaidamaka <[email protected]>
Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
Co-authored-by: Nikolai Kochetov <[email protected]>
Co-authored-by: Ivan Blinkov <[email protected]>
Co-authored-by: BayoNet <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Roman Bug <[email protected]>
Co-authored-by: romanzhukov <[email protected]>
Co-authored-by: tavplubix <[email protected]>
Co-authored-by: Alexander Kuzmenkov <[email protected]>
Co-authored-by: Ivan <[email protected]>
Co-authored-by: Azat Khuzhin <[email protected]>
Co-authored-by: chengy8934 <[email protected]>
Co-authored-by: MicrochipQ <[email protected]>
Co-authored-by: Artem Zuikov <[email protected]>
Co-authored-by: Alexander Kazakov <[email protected]>
Co-authored-by: Vladimir Chebotarev <[email protected]>
Co-authored-by: Nicolae Vartolomei <[email protected]>
Co-authored-by: filimonov <[email protected]>
Co-authored-by: olgarev <[email protected]>
Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: AsiaKorushkina <[email protected]>
Co-authored-by: asiana21 <[email protected]>
Co-authored-by: zhang2014 <[email protected]>
Co-authored-by: Evgenia Sudarikova <[email protected]>
Co-authored-by: Anton Popov <[email protected]>
Co-authored-by: manmitya <[email protected]>
Co-authored-by: Nikolai Kochetov <[email protected]>
Co-authored-by: Mikhail Filimonov <[email protected]>
Co-authored-by: Ilya Yatsishin <[email protected]>
Co-authored-by: tavplubix <[email protected]>
alexey-milovidov added a commit that referenced this pull request Jul 7, 2020
* longer

* muzzy decay 10 ms

* Support Enums type for MySQL engine #3985

* performance comparison

* Add integration test for MySQL enums type

* Fix bad log message at server startup

* Insert enum column values for test

* Better diagnostics of "Replica {} appears to be already active" message

* Fix typos

* Added a test for #8550

* Update extended-roadmap.md

* Update test

* Fix FPE, step 1

* Make it more correct

* Add a test

* Avoid floating point error in geohashesInBox #11369

* Avro: allow missing fields

* update

* Fix build

* Revert "[experiment] maybe fix warnings in integration tests"

* Add xeus-clickhouse (#12010)

xeus-clickhouse is a Jupyter kernal for ClickHouse

* Fix test

* Fix array size overflow in generateRandom

* Added a test

* Update ErrorCodes.cpp

* More hardening

* More hardening

* Move reading from RabbitMQ into background task

* Fix access rights: cannot grant DDL when allow_ddl=0

* Add tests

* Add test test_allow_ddl.

* Added failing test

* Remove the usage of obsolete setting

* Whitespace

* Added a test

* Allow to ALTER partition key in some cases

* Slightly more safe

* Only allow Enum extension within the same width

* Update test

* Added failing test for Replicated table

* Fix clang-tidy

* Whitespace

* Write partition key changes to ZooKeeper

* Typos

* Implement for ReplicatedMergeTree

* Added test reference

* Added missing ORDER BY in test

* Fix integration test

* Fix error in addMonths with floating point argument

* Fix error in addMonths with floating point argument

* Fix overflow in function "neighbor"

* Whitespace

* Whitespace

* Fix ORDER BY tuple with COLLATE on const column

* clickhouse-local: logging flags fixes

* clickhouse-local: use std::filesystem::equivalent

* Limit /proc/cpuinfo metrics to linux only

* Feature 8074 (#12014)

* refs #8074 1: start to stream

* refs final check format and spell

* refs final check format and spell

* refs #8074 fix up link to sql-reference/functions/other-functions

* Bump idna from 2.9 to 2.10 in /docs/tools

Bumps [idna](https://github.com/kjd/idna) from 2.9 to 2.10.
- [Release notes](https://github.com/kjd/idna/releases)
- [Changelog](https://github.com/kjd/idna/blob/master/HISTORY.rst)
- [Commits](kjd/idna@v2.9...v2.10)

Signed-off-by: dependabot-preview[bot] <[email protected]>

* make a short test for DateTime

* Fixup

* DOCS-636 Synchronized some edits from EN to RU (#11941)

* [review][clickhousedocs][translate] DOCSUP-1351: Edit and translate to Russian (#129)

* DOCSUP-1351: Add blockSerializedSize (RU)

* DOCSUP-1351: Fix blockSerializedSize description by function description template.

* DOCSUP-1351: PR8756- Update Distributed engine section.

* DOCSUP-1351: PR9076-Show Queries more like MySQL did.

* DOCSUP-1351: PR#9919-system.tables improvements (total_rows/total_bytes/storage_policy)

* DOCSUP-1351: (ru) blockSerializedSize remake by template.

* DOCSUP-1351: PR#9598-Add function arrayReduceInRange and update arrayReduce function.

* DOCSUP-1351: PR#9598 Fix arrayReduce and arrayReduceInRanges sections by template.

* DOCSUP-1351: Some fixes.

* DOCSUP-1351: Some fixes.

Co-authored-by: romanzhukov <[email protected]>

* CLICKHOUSEDOCS-636: Minor changes.

Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Roman Bug <[email protected]>
Co-authored-by: romanzhukov <[email protected]>

* Use ConcurentBoundedQueue instead of vector

* Temporary enable debug logs when releasing docs

* Better docker images list

* [docs] improve stable releases discovery

* Update contrib/jemalloc-cmake/CMakeLists.txt

* Remove libevent library

* Automated backporting machinery (#12029)

* Add automated cherry-pick machinery

* Added script for backporting machinery

* Implement dry-run mode

* Comment old methods

* Fix python2

* Add ya.make for sandbox tasks

* Remove old stuff

* Move writing to RabbitMQ into background task

* Add TLB misses perf counters.

* Update ThreadProfileEvents.cpp

* Fake change in dockerfile

* Fix tuple nullable comparison.

* Fix access rights: cannot grant INTROSPECTION when allow_introspection_functions=0.

* fixup

* Update ThreadProfileEvents.cpp

* Fix test.

* Added test.

* Fix and simplify code

* Fix test.

* Update ITransformingStep.h

* Fix "Sharding key is not deterministic" message

* Do not check *optimize_skip_unused_shards_nesting w/o *optimize_skip_unused_shards

This will avoid supperior log message in case of
*optimize_skip_unused_shards_nesting already disables it.
And also it is logical.

* Remove test that is not supported by "Arcadia" build system

* Make topK return Enum for Enum types

* parse metadata in parallel when loading tables

* Fix build

* fixup

* Update ThreadProfileEvents.cpp

* Update browse-code.md (#12047)

* Update browse-code.md

纠正了一些翻译错误。

* Update browse-code.md

Co-authored-by: Ivan Blinkov <[email protected]>

* Bump python-slugify from 1.2.6 to 4.0.1 in /docs/tools

Bumps [python-slugify](https://github.com/un33k/python-slugify) from 1.2.6 to 4.0.1.
- [Release notes](https://github.com/un33k/python-slugify/releases)
- [Changelog](https://github.com/un33k/python-slugify/blob/master/CHANGELOG.md)
- [Commits](un33k/python-slugify@1.2.6...4.0.1)

Signed-off-by: dependabot-preview[bot] <[email protected]>

* Update ThreadProfileEvents.cpp

* Update README.md

* Fix typo (#12046)

* Fix test_allow_introspection.

* Try fix labda tuple(LC) argument.

* Test image changes

* Try fix labda tuple(LC) argument.

* Add pvs studio to images

* Added test.

* fix low card types in merge join (#12035)

* Update contrib/poco to ClickHouse-Extras/poco #22 (#12037)

* Updated ClickHouse-Extras/poco #22

* Fix defaultValueOfArgumentType

* Added test.

* Update cpu_synthetic.xml

* Moves task shall be started if new storage policy needs them.

* Added test for automatic start of background move task.

* Add ability to run any image version from packager and runner

* Try fix pk in tuple performance

Possible approach for fixing #10574

The problem is that prepared sets are built correctly, it is a hash map of key -> set
where key is a hash of AST and list of data types (when we a list of
tuples of literals).

However, when the key is built from the index to try and find if there
exists a prepared set that would match it looks for data types of the
primary key (see how data_types is populated) because the primary key
has only one field (v in my example) it can not find the prepared set.

The patch looks for any prepared indexes where data types match for the
subset of fields found in primary key, we are not interested in other
fields anyway for the purpose of primary key pruning.

* Fix partial revokes (complex cases).

* Changelog for 20.3.11, 12

* simple changelog script

* bump CI

* Add explicit test for a case where AST hashes collide for different prepared sets

* [blog] add RSS feed (#12064)

* [blog] add rss feed

* better title

* Update CHANGELOG.md

Co-authored-by: Ivan Blinkov <[email protected]>

* bump ci

* Moved useless S3 logging to TRACE level.

* Add a test to cover non-const tuple elemenets (just in case)

* Bump

* Update query-complexity.md

Remove a note about read limits applied on threads level.

* Update query-complexity.md

* Update query-complexity.md

* Update query-complexity.md

* DOCS-609: max_server_memory_usage (#11771)

* Revolg DOCSUP-1000 add max server memory usage setting (#125)

* Add max_server_memory_usage setting, delete max_memory_usage_for_all_queries setting.

* Syntax fixed

* Apply suggestions from code review

Co-authored-by: BayoNet <[email protected]>

* Doc for the max_server_memory_usage setting. Updates.

Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-609: Minor fixes.

* CLICKHOUSEDOCS-609: Actualized position of the setting.

Co-authored-by: olgarev <[email protected]>
Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>

* Add force_primary_key to a pk in tuple test

* DOCS-510: runningAccumulate (#12061)

* asiana21-DOCSUP-797 (#117)

* docs(runningAccumulate): the function description is added

* docs(runningAccumulate): the function description is modified

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* docs(runningAccumulate): some changes

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* docs(runningAccumulate): added ru translation

Co-authored-by: asiana21 <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-510: Minor fix.

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: Ivan Blinkov <[email protected]>

* CLICKHOUSEDOCS-510: Fixed links.

Co-authored-by: AsiaKorushkina <[email protected]>
Co-authored-by: asiana21 <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Ivan Blinkov <[email protected]>

* Remove const specifier to allow auto-move (clangtidy)

* Rewrite Set lookup to make it more readable

* [docs] Sync zh/development/build-osx.md from EN (#12071)

* ISSUES-4006 support first for ALTER ADD|MODIFY COLUMN

* Update deb image

* Don't download image twice

* Remove garbage from images

* bump ci

* fixup

* DOCS-635: Translated the EN version of the AvroConfluent format description (#11930)

* DOCSUP-1350 (#128)

* edited EN version

* add EN and RU translation

* minor changes

* CLICKHOUSEDOCS-635: Updated the description.

Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Evgenia Sudarikova <[email protected]>

* Better PVS image

* DOCS-605: Description for the always_fetch_merged_part setting (#11921)

* Revolg DOCSUP-998 Document the always_fetch_merged_part setting (#123)

* Add always_fetch_merged_part setting

* revolg-DOCSUP-998-add_always_fetch_merged_part_setting link fixed

* Apply suggestions from code review

Co-authored-by: BayoNet <[email protected]>

* Add always_fetch_merged_part setting. Updates.

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* Add always_fetch_merged_part setting. Updates.

Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-605: Minor fixes.

* CLICKHOUSEDOCS-605: Added Plausible to Adopters.

* Update docs/ru/operations/settings/settings.md

Co-authored-by: alesapin <[email protected]>

* Update docs/en/operations/settings/settings.md

Co-authored-by: alesapin <[email protected]>

* CLICKHOUSEDOCS-605: Fixed access rights description.

Co-authored-by: olgarev <[email protected]>
Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: alesapin <[email protected]>

* Update Dockerfile

* revert e9d3c48

* [blog] 'Package Repository Behind CDN' post (#12082)

* support iframes from DataLens

* initial blog post text

* Improve REVOKE command: now it requires only grant/admin option for only
access which will be revoked.
REVOKE ALL FROM user1 now revokes all granted roles.

* Fix limiting the number of threads for VIEW.

* Update tips.md

* Added test.

* Remove pvs studio from images list

* Better shutdown and conversion

* Reverse arguments

* improve breadcrumbs markup

* Less race conditions

* [docker] install ca-certificates before the first apt-get update (#12095)

* [docker] install ca-certificates before first apt-get update

* Update Dockerfile

* DOCS-522: max_parser_depth (#12097)

* asiana21-DOCSUP-925-max_parser_depth (#132)

* docs(max_parser_depth): added the setting description

* docs(max_parser_depth): some changes

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* docs(max_parser_depth): added ru translation

* docs(max_parser_depth): removed quotation marks

Co-authored-by: asiana21 <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-522: Fixed the link.

Co-authored-by: AsiaKorushkina <[email protected]>
Co-authored-by: asiana21 <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>

* Added results for AWS Lightsail

* (typo) in doc (#12099)

* Create codeql-analysis.yml

* Tiny fixes

* Create anchore-analysis.yml

* Update README.md

* Fix test (#12088)

* Test for a fixed issue #10668, related to input_format_allow_errors_num in CSV

* Add unbundled mode flag

* Remove LC converting to Arrow.

* Remove LC converting to Arrow.

* Move skip lists to clickhouse-test

* Remove LC converting to Arrow.

* More verbose message about skip

* Make skip-list optional

* Added test.

* Update clickhouse-test

* Update 01355_CSV_input_format_allow_errors.sh

* Added a showcase of minimal Docker image

* Added a comment

* Added a comment

* Added a comment

* Formatting

* contrib/unixodbc-cmake: Fix build when UNBUNDLED

target_compile_definitions may only set INTERFACE properties on IMPORTED targets

* Fix version column in replicated version collapsing merge tree (#12121)

* poco-cmake: Fix Poco::Data::ODBC target when UNBUNDLED

By default IMPORTED target has a scope in the directory in which it is created
and below. This leads to the following issues when building UNBUNDLED:

Target "clickhouse" links to target "Poco::Data::ODBC" but the target was not
found.  Perhaps a find_package() call is missing for an IMPORTED target, or an
ALIAS target is missing?

* Improve performace of reading in order of sorting key. (#11696)

* simplify reading in order of sorting key

* add perf test for reading many parts

* Revert "simplify reading in order of sorting key"

This reverts commit 7267d7c.

* add threshold for preliminary merge for reading in order

* better threshold

* limit threads in test

* Normalize "pid" file handling #3501

* Update StatusFile.cpp

Co-authored-by: Alexander Kuzmenkov <[email protected]>
Co-authored-by: BohuTANG <[email protected]>
Co-authored-by: Nikita Mikhaylov <[email protected]>
Co-authored-by: Alexey Milovidov <[email protected]>
Co-authored-by: Andrew Onyshchuk <[email protected]>
Co-authored-by: feng lv <[email protected]>
Co-authored-by: alesapin <[email protected]>
Co-authored-by: Wang Fenjin <[email protected]>
Co-authored-by: kssenii <[email protected]>
Co-authored-by: Vitaly Baranov <[email protected]>
Co-authored-by: Mikhail Gaidamaka <[email protected]>
Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
Co-authored-by: Nikolai Kochetov <[email protected]>
Co-authored-by: Ivan Blinkov <[email protected]>
Co-authored-by: BayoNet <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Roman Bug <[email protected]>
Co-authored-by: romanzhukov <[email protected]>
Co-authored-by: tavplubix <[email protected]>
Co-authored-by: Alexander Kuzmenkov <[email protected]>
Co-authored-by: Ivan <[email protected]>
Co-authored-by: Azat Khuzhin <[email protected]>
Co-authored-by: chengy8934 <[email protected]>
Co-authored-by: MicrochipQ <[email protected]>
Co-authored-by: Artem Zuikov <[email protected]>
Co-authored-by: Alexander Kazakov <[email protected]>
Co-authored-by: Vladimir Chebotarev <[email protected]>
Co-authored-by: Nicolae Vartolomei <[email protected]>
Co-authored-by: filimonov <[email protected]>
Co-authored-by: olgarev <[email protected]>
Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: AsiaKorushkina <[email protected]>
Co-authored-by: asiana21 <[email protected]>
Co-authored-by: zhang2014 <[email protected]>
Co-authored-by: Evgenia Sudarikova <[email protected]>
Co-authored-by: Anton Popov <[email protected]>
Co-authored-by: manmitya <[email protected]>
Co-authored-by: Nikolai Kochetov <[email protected]>
Co-authored-by: Mikhail Filimonov <[email protected]>
Co-authored-by: Ilya Yatsishin <[email protected]>
Co-authored-by: tavplubix <[email protected]>
Co-authored-by: Matwey V. Kornilov <[email protected]>
alexey-milovidov added a commit that referenced this pull request Jul 7, 2020
…f different sizes (#12241)

* Whitespace

* Added a test

* Allow to ALTER partition key in some cases

* Slightly more safe

* Only allow Enum extension within the same width

* Update test

* Added failing test for Replicated table

* Fix clang-tidy

* Whitespace

* Write partition key changes to ZooKeeper

* Typos

* Implement for ReplicatedMergeTree

* Added test reference

* Added missing ORDER BY in test

* Fix integration test

* Fix error in addMonths with floating point argument

* Fix error in addMonths with floating point argument

* Fix overflow in function "neighbor"

* Whitespace

* Whitespace

* Fix ORDER BY tuple with COLLATE on const column

* clickhouse-local: logging flags fixes

* clickhouse-local: use std::filesystem::equivalent

* Limit /proc/cpuinfo metrics to linux only

* Feature 8074 (#12014)

* refs #8074 1: start to stream

* refs final check format and spell

* refs final check format and spell

* refs #8074 fix up link to sql-reference/functions/other-functions

* Bump idna from 2.9 to 2.10 in /docs/tools

Bumps [idna](https://github.com/kjd/idna) from 2.9 to 2.10.
- [Release notes](https://github.com/kjd/idna/releases)
- [Changelog](https://github.com/kjd/idna/blob/master/HISTORY.rst)
- [Commits](kjd/idna@v2.9...v2.10)

Signed-off-by: dependabot-preview[bot] <[email protected]>

* make a short test for DateTime

* Fixup

* DOCS-636 Synchronized some edits from EN to RU (#11941)

* [review][clickhousedocs][translate] DOCSUP-1351: Edit and translate to Russian (#129)

* DOCSUP-1351: Add blockSerializedSize (RU)

* DOCSUP-1351: Fix blockSerializedSize description by function description template.

* DOCSUP-1351: PR8756- Update Distributed engine section.

* DOCSUP-1351: PR9076-Show Queries more like MySQL did.

* DOCSUP-1351: PR#9919-system.tables improvements (total_rows/total_bytes/storage_policy)

* DOCSUP-1351: (ru) blockSerializedSize remake by template.

* DOCSUP-1351: PR#9598-Add function arrayReduceInRange and update arrayReduce function.

* DOCSUP-1351: PR#9598 Fix arrayReduce and arrayReduceInRanges sections by template.

* DOCSUP-1351: Some fixes.

* DOCSUP-1351: Some fixes.

Co-authored-by: romanzhukov <[email protected]>

* CLICKHOUSEDOCS-636: Minor changes.

Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Roman Bug <[email protected]>
Co-authored-by: romanzhukov <[email protected]>

* Use ConcurentBoundedQueue instead of vector

* Temporary enable debug logs when releasing docs

* Better docker images list

* [docs] improve stable releases discovery

* Update contrib/jemalloc-cmake/CMakeLists.txt

* Remove libevent library

* Automated backporting machinery (#12029)

* Add automated cherry-pick machinery

* Added script for backporting machinery

* Implement dry-run mode

* Comment old methods

* Fix python2

* Add ya.make for sandbox tasks

* Remove old stuff

* Move writing to RabbitMQ into background task

* Add TLB misses perf counters.

* Update ThreadProfileEvents.cpp

* Fake change in dockerfile

* Fix tuple nullable comparison.

* Fix access rights: cannot grant INTROSPECTION when allow_introspection_functions=0.

* fixup

* Update ThreadProfileEvents.cpp

* Fix test.

* Added test.

* Fix and simplify code

* Fix test.

* Update ITransformingStep.h

* Fix "Sharding key is not deterministic" message

* Do not check *optimize_skip_unused_shards_nesting w/o *optimize_skip_unused_shards

This will avoid supperior log message in case of
*optimize_skip_unused_shards_nesting already disables it.
And also it is logical.

* Fix function if with FixedString arguments of different sizes

* Add multiIf

* Fix error

* Remove test that is not supported by "Arcadia" build system

* Fix constraints check for constant columns

* Make topK return Enum for Enum types

* parse metadata in parallel when loading tables

* Fix error

* Fix build

* fixup

* Update ThreadProfileEvents.cpp

* Update browse-code.md (#12047)

* Update browse-code.md

纠正了一些翻译错误。

* Update browse-code.md

Co-authored-by: Ivan Blinkov <[email protected]>

* Bump python-slugify from 1.2.6 to 4.0.1 in /docs/tools

Bumps [python-slugify](https://github.com/un33k/python-slugify) from 1.2.6 to 4.0.1.
- [Release notes](https://github.com/un33k/python-slugify/releases)
- [Changelog](https://github.com/un33k/python-slugify/blob/master/CHANGELOG.md)
- [Commits](un33k/python-slugify@1.2.6...4.0.1)

Signed-off-by: dependabot-preview[bot] <[email protected]>

* Update ThreadProfileEvents.cpp

* Update README.md

* Fix typo (#12046)

* Fix test_allow_introspection.

* Try fix labda tuple(LC) argument.

* Test image changes

* Try fix labda tuple(LC) argument.

* Add pvs studio to images

* Added test.

* fix low card types in merge join (#12035)

* Update contrib/poco to ClickHouse-Extras/poco #22 (#12037)

* Updated ClickHouse-Extras/poco #22

* Fix defaultValueOfArgumentType

* Added test.

* Update cpu_synthetic.xml

* Moves task shall be started if new storage policy needs them.

* Added test for automatic start of background move task.

* Add ability to run any image version from packager and runner

* Check type of filter for prewhere.

* Check type of filter for prewhere.

* Check type of filter for prewhere.

* Check type of filter for prewhere.

* Added test.

* Try fix pk in tuple performance

Possible approach for fixing #10574

The problem is that prepared sets are built correctly, it is a hash map of key -> set
where key is a hash of AST and list of data types (when we a list of
tuples of literals).

However, when the key is built from the index to try and find if there
exists a prepared set that would match it looks for data types of the
primary key (see how data_types is populated) because the primary key
has only one field (v in my example) it can not find the prepared set.

The patch looks for any prepared indexes where data types match for the
subset of fields found in primary key, we are not interested in other
fields anyway for the purpose of primary key pruning.

* Fix partial revokes (complex cases).

* Changelog for 20.3.11, 12

* simple changelog script

* bump CI

* Fix tests.

* Add explicit test for a case where AST hashes collide for different prepared sets

* [blog] add RSS feed (#12064)

* [blog] add rss feed

* better title

* Update CHANGELOG.md

Co-authored-by: Ivan Blinkov <[email protected]>

* bump ci

* Moved useless S3 logging to TRACE level.

* Add a test to cover non-const tuple elemenets (just in case)

* Bump

* Update query-complexity.md

Remove a note about read limits applied on threads level.

* Update query-complexity.md

* Update query-complexity.md

* Update query-complexity.md

* DOCS-609: max_server_memory_usage (#11771)

* Revolg DOCSUP-1000 add max server memory usage setting (#125)

* Add max_server_memory_usage setting, delete max_memory_usage_for_all_queries setting.

* Syntax fixed

* Apply suggestions from code review

Co-authored-by: BayoNet <[email protected]>

* Doc for the max_server_memory_usage setting. Updates.

Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-609: Minor fixes.

* CLICKHOUSEDOCS-609: Actualized position of the setting.

Co-authored-by: olgarev <[email protected]>
Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>

* Add force_primary_key to a pk in tuple test

* DOCS-510: runningAccumulate (#12061)

* asiana21-DOCSUP-797 (#117)

* docs(runningAccumulate): the function description is added

* docs(runningAccumulate): the function description is modified

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* docs(runningAccumulate): some changes

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* docs(runningAccumulate): added ru translation

Co-authored-by: asiana21 <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-510: Minor fix.

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: Ivan Blinkov <[email protected]>

* CLICKHOUSEDOCS-510: Fixed links.

Co-authored-by: AsiaKorushkina <[email protected]>
Co-authored-by: asiana21 <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Ivan Blinkov <[email protected]>

* Remove const specifier to allow auto-move (clangtidy)

* Rewrite Set lookup to make it more readable

* [docs] Sync zh/development/build-osx.md from EN (#12071)

* ISSUES-4006 support first for ALTER ADD|MODIFY COLUMN

* Update deb image

* Don't download image twice

* Remove garbage from images

* bump ci

* fixup

* DOCS-635: Translated the EN version of the AvroConfluent format description (#11930)

* DOCSUP-1350 (#128)

* edited EN version

* add EN and RU translation

* minor changes

* CLICKHOUSEDOCS-635: Updated the description.

Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Evgenia Sudarikova <[email protected]>

* Fix tests.

* Better PVS image

* DOCS-605: Description for the always_fetch_merged_part setting (#11921)

* Revolg DOCSUP-998 Document the always_fetch_merged_part setting (#123)

* Add always_fetch_merged_part setting

* revolg-DOCSUP-998-add_always_fetch_merged_part_setting link fixed

* Apply suggestions from code review

Co-authored-by: BayoNet <[email protected]>

* Add always_fetch_merged_part setting. Updates.

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* Add always_fetch_merged_part setting. Updates.

Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-605: Minor fixes.

* CLICKHOUSEDOCS-605: Added Plausible to Adopters.

* Update docs/ru/operations/settings/settings.md

Co-authored-by: alesapin <[email protected]>

* Update docs/en/operations/settings/settings.md

Co-authored-by: alesapin <[email protected]>

* CLICKHOUSEDOCS-605: Fixed access rights description.

Co-authored-by: olgarev <[email protected]>
Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: alesapin <[email protected]>

* Update Dockerfile

* revert e9d3c48

* [blog] 'Package Repository Behind CDN' post (#12082)

* support iframes from DataLens

* initial blog post text

* Improve REVOKE command: now it requires only grant/admin option for only
access which will be revoked.
REVOKE ALL FROM user1 now revokes all granted roles.

* Fix limiting the number of threads for VIEW.

* Update tips.md

* Added test.

* Remove pvs studio from images list

* Better shutdown and conversion

* Reverse arguments

* Fix result_rows and result_bytes metrics for selects.

* Fix result_rows and result_bytes metrics for selects.

* improve breadcrumbs markup

* Fix tests.

* Less race conditions

* [docker] install ca-certificates before the first apt-get update (#12095)

* [docker] install ca-certificates before first apt-get update

* Update Dockerfile

* DOCS-522: max_parser_depth (#12097)

* asiana21-DOCSUP-925-max_parser_depth (#132)

* docs(max_parser_depth): added the setting description

* docs(max_parser_depth): some changes

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* docs(max_parser_depth): added ru translation

* docs(max_parser_depth): removed quotation marks

Co-authored-by: asiana21 <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-522: Fixed the link.

Co-authored-by: AsiaKorushkina <[email protected]>
Co-authored-by: asiana21 <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>

* Added results for AWS Lightsail

* (typo) in doc (#12099)

* Added test.

* Create codeql-analysis.yml

* Tiny fixes

* Create anchore-analysis.yml

* Update README.md

* Fix test (#12088)

* Test for a fixed issue #10668, related to input_format_allow_errors_num in CSV

* Add unbundled mode flag

* Remove LC converting to Arrow.

* Remove LC converting to Arrow.

* Move skip lists to clickhouse-test

* Remove LC converting to Arrow.

* More verbose message about skip

* Make skip-list optional

* Added test.

* Add type column in system.disks

* Update clickhouse-test

* Update 01355_CSV_input_format_allow_errors.sh

* Added a showcase of minimal Docker image

* Added a comment

* Added a comment

* Added a comment

* Formatting

* contrib/unixodbc-cmake: Fix build when UNBUNDLED

target_compile_definitions may only set INTERFACE properties on IMPORTED targets

* Fix version column in replicated version collapsing merge tree (#12121)

* poco-cmake: Fix Poco::Data::ODBC target when UNBUNDLED

By default IMPORTED target has a scope in the directory in which it is created
and below. This leads to the following issues when building UNBUNDLED:

Target "clickhouse" links to target "Poco::Data::ODBC" but the target was not
found.  Perhaps a find_package() call is missing for an IMPORTED target, or an
ALIAS target is missing?

* Add missed <atomic> include in ProxyListConfiguration

* Improve performace of reading in order of sorting key. (#11696)

* simplify reading in order of sorting key

* add perf test for reading many parts

* Revert "simplify reading in order of sorting key"

This reverts commit 7267d7c.

* add threshold for preliminary merge for reading in order

* better threshold

* limit threads in test

* Normalize "pid" file handling #3501

* Update StatusFile.cpp

* Added a test

* Remove harmful code from "geoDistance" #12117

* Fix warnings from CodeQL

* Added a test

* Minor modification

* Update libdivide to the latest master

* Replace exit to abort in libdivide

* Fix potential overflow in integer division #12119

* Added a test

* Whitespace

* Added a test for #4211

* Attempt to fix "Arcadia" build

* Rename test

* Update arraySum.cpp

* ILIKE operator (#12125)

* Integrated CachingAllocator into MarkCache

* fixed build errors

* reset func hotfix

* upd: Fixing build

* updated submodules links

* fix 2

* updating grabber allocator proto

* updating lost work

* updating CMake to use concepts

* some other changes to get it building (integration into MarkCache)

* further integration into caches

* updated Async metrics, fixed some build errors

* and some other errors revealing

* added perfect forwarding to some functions

* fix: forward template

* fix: constexpr modifier

* fix: FakePODAllocator missing member func

* updated PODArray constructor taking alloc params

* fix: PODArray overload with n restored

* fix: FakePODAlloc duplicating alloc() func

* added constexpr variable for alloc_tag_t

* split cache values by allocators, provided updates

* fix: memcpy

* fix: constexpr modifier

* fix: noexcept modifier

* fix: alloc_tag_t for PODArray constructor

* fix: PODArray copy ctor with different alloc

* fix: resize() signature

* updating to lastest working master

* syncing with 273267

* first draft version

* fix: update Searcher to case-insensitive

* added ILIKE test

* fixed style errors, updated test, split like and ilike,  added notILike

* replaced inconsistent comments

* fixed show tables ilike

* updated missing test cases

* regenerated ya.make

* Update 01355_ilike.sql

Co-authored-by: myrrc <[email protected]>
Co-authored-by: alexey-milovidov <[email protected]>

Co-authored-by: Alexey Milovidov <[email protected]>
Co-authored-by: Andrew Onyshchuk <[email protected]>
Co-authored-by: Mikhail Gaidamaka <[email protected]>
Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
Co-authored-by: Alexander Kuzmenkov <[email protected]>
Co-authored-by: Nikolai Kochetov <[email protected]>
Co-authored-by: Ivan Blinkov <[email protected]>
Co-authored-by: alesapin <[email protected]>
Co-authored-by: BayoNet <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Roman Bug <[email protected]>
Co-authored-by: romanzhukov <[email protected]>
Co-authored-by: kssenii <[email protected]>
Co-authored-by: tavplubix <[email protected]>
Co-authored-by: Alexander Kuzmenkov <[email protected]>
Co-authored-by: Ivan <[email protected]>
Co-authored-by: Vitaly Baranov <[email protected]>
Co-authored-by: Nikita Mikhaylov <[email protected]>
Co-authored-by: Azat Khuzhin <[email protected]>
Co-authored-by: chengy8934 <[email protected]>
Co-authored-by: MicrochipQ <[email protected]>
Co-authored-by: Artem Zuikov <[email protected]>
Co-authored-by: Alexander Kazakov <[email protected]>
Co-authored-by: Vladimir Chebotarev <[email protected]>
Co-authored-by: Nicolae Vartolomei <[email protected]>
Co-authored-by: filimonov <[email protected]>
Co-authored-by: olgarev <[email protected]>
Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: AsiaKorushkina <[email protected]>
Co-authored-by: asiana21 <[email protected]>
Co-authored-by: BohuTANG <[email protected]>
Co-authored-by: zhang2014 <[email protected]>
Co-authored-by: Evgenia Sudarikova <[email protected]>
Co-authored-by: Anton Popov <[email protected]>
Co-authored-by: manmitya <[email protected]>
Co-authored-by: Nikolai Kochetov <[email protected]>
Co-authored-by: Mikhail Filimonov <[email protected]>
Co-authored-by: Anton Ivashkin <[email protected]>
Co-authored-by: Ilya Yatsishin <[email protected]>
Co-authored-by: tavplubix <[email protected]>
Co-authored-by: Matwey V. Kornilov <[email protected]>
Co-authored-by: myrrc <[email protected]>
Co-authored-by: myrrc <[email protected]>
alexey-milovidov added a commit that referenced this pull request Jul 7, 2020
…#12240)

* Fixup

* DOCS-636 Synchronized some edits from EN to RU (#11941)

* [review][clickhousedocs][translate] DOCSUP-1351: Edit and translate to Russian (#129)

* DOCSUP-1351: Add blockSerializedSize (RU)

* DOCSUP-1351: Fix blockSerializedSize description by function description template.

* DOCSUP-1351: PR8756- Update Distributed engine section.

* DOCSUP-1351: PR9076-Show Queries more like MySQL did.

* DOCSUP-1351: PR#9919-system.tables improvements (total_rows/total_bytes/storage_policy)

* DOCSUP-1351: (ru) blockSerializedSize remake by template.

* DOCSUP-1351: PR#9598-Add function arrayReduceInRange and update arrayReduce function.

* DOCSUP-1351: PR#9598 Fix arrayReduce and arrayReduceInRanges sections by template.

* DOCSUP-1351: Some fixes.

* DOCSUP-1351: Some fixes.

Co-authored-by: romanzhukov <[email protected]>

* CLICKHOUSEDOCS-636: Minor changes.

Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Roman Bug <[email protected]>
Co-authored-by: romanzhukov <[email protected]>

* Use ConcurentBoundedQueue instead of vector

* Temporary enable debug logs when releasing docs

* Better docker images list

* [docs] improve stable releases discovery

* Update contrib/jemalloc-cmake/CMakeLists.txt

* Remove libevent library

* Automated backporting machinery (#12029)

* Add automated cherry-pick machinery

* Added script for backporting machinery

* Implement dry-run mode

* Comment old methods

* Fix python2

* Add ya.make for sandbox tasks

* Remove old stuff

* Move writing to RabbitMQ into background task

* Add TLB misses perf counters.

* Update ThreadProfileEvents.cpp

* Fake change in dockerfile

* Fix tuple nullable comparison.

* Fix access rights: cannot grant INTROSPECTION when allow_introspection_functions=0.

* fixup

* Update ThreadProfileEvents.cpp

* Fix test.

* Added test.

* Fix and simplify code

* Fix test.

* Update ITransformingStep.h

* Fix "Sharding key is not deterministic" message

* Do not check *optimize_skip_unused_shards_nesting w/o *optimize_skip_unused_shards

This will avoid supperior log message in case of
*optimize_skip_unused_shards_nesting already disables it.
And also it is logical.

* Fix function if with FixedString arguments of different sizes

* Add multiIf

* Fix error

* Remove test that is not supported by "Arcadia" build system

* Fix constraints check for constant columns

* Make topK return Enum for Enum types

* parse metadata in parallel when loading tables

* Fix error

* Fix build

* fixup

* Update ThreadProfileEvents.cpp

* Update browse-code.md (#12047)

* Update browse-code.md

纠正了一些翻译错误。

* Update browse-code.md

Co-authored-by: Ivan Blinkov <[email protected]>

* Bump python-slugify from 1.2.6 to 4.0.1 in /docs/tools

Bumps [python-slugify](https://github.com/un33k/python-slugify) from 1.2.6 to 4.0.1.
- [Release notes](https://github.com/un33k/python-slugify/releases)
- [Changelog](https://github.com/un33k/python-slugify/blob/master/CHANGELOG.md)
- [Commits](un33k/python-slugify@1.2.6...4.0.1)

Signed-off-by: dependabot-preview[bot] <[email protected]>

* Update ThreadProfileEvents.cpp

* Update README.md

* Fix typo (#12046)

* Fix test_allow_introspection.

* Try fix labda tuple(LC) argument.

* Test image changes

* Try fix labda tuple(LC) argument.

* Add pvs studio to images

* Added test.

* fix low card types in merge join (#12035)

* Update contrib/poco to ClickHouse-Extras/poco #22 (#12037)

* Updated ClickHouse-Extras/poco #22

* Fix defaultValueOfArgumentType

* Added test.

* Update cpu_synthetic.xml

* Moves task shall be started if new storage policy needs them.

* Added test for automatic start of background move task.

* Add ability to run any image version from packager and runner

* Check type of filter for prewhere.

* Check type of filter for prewhere.

* Check type of filter for prewhere.

* Check type of filter for prewhere.

* Added test.

* Try fix pk in tuple performance

Possible approach for fixing #10574

The problem is that prepared sets are built correctly, it is a hash map of key -> set
where key is a hash of AST and list of data types (when we a list of
tuples of literals).

However, when the key is built from the index to try and find if there
exists a prepared set that would match it looks for data types of the
primary key (see how data_types is populated) because the primary key
has only one field (v in my example) it can not find the prepared set.

The patch looks for any prepared indexes where data types match for the
subset of fields found in primary key, we are not interested in other
fields anyway for the purpose of primary key pruning.

* Fix partial revokes (complex cases).

* Changelog for 20.3.11, 12

* simple changelog script

* bump CI

* Fix tests.

* Add explicit test for a case where AST hashes collide for different prepared sets

* [blog] add RSS feed (#12064)

* [blog] add rss feed

* better title

* Update CHANGELOG.md

Co-authored-by: Ivan Blinkov <[email protected]>

* bump ci

* Moved useless S3 logging to TRACE level.

* Add a test to cover non-const tuple elemenets (just in case)

* Bump

* Update query-complexity.md

Remove a note about read limits applied on threads level.

* Update query-complexity.md

* Update query-complexity.md

* Update query-complexity.md

* DOCS-609: max_server_memory_usage (#11771)

* Revolg DOCSUP-1000 add max server memory usage setting (#125)

* Add max_server_memory_usage setting, delete max_memory_usage_for_all_queries setting.

* Syntax fixed

* Apply suggestions from code review

Co-authored-by: BayoNet <[email protected]>

* Doc for the max_server_memory_usage setting. Updates.

Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-609: Minor fixes.

* CLICKHOUSEDOCS-609: Actualized position of the setting.

Co-authored-by: olgarev <[email protected]>
Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>

* Add force_primary_key to a pk in tuple test

* DOCS-510: runningAccumulate (#12061)

* asiana21-DOCSUP-797 (#117)

* docs(runningAccumulate): the function description is added

* docs(runningAccumulate): the function description is modified

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* docs(runningAccumulate): some changes

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* docs(runningAccumulate): added ru translation

Co-authored-by: asiana21 <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-510: Minor fix.

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: Ivan Blinkov <[email protected]>

* CLICKHOUSEDOCS-510: Fixed links.

Co-authored-by: AsiaKorushkina <[email protected]>
Co-authored-by: asiana21 <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Ivan Blinkov <[email protected]>

* Remove const specifier to allow auto-move (clangtidy)

* Rewrite Set lookup to make it more readable

* [docs] Sync zh/development/build-osx.md from EN (#12071)

* ISSUES-4006 support first for ALTER ADD|MODIFY COLUMN

* Update deb image

* Don't download image twice

* Remove garbage from images

* bump ci

* Changelog for 20.1, 20.4

* fixup

* DOCS-635: Translated the EN version of the AvroConfluent format description (#11930)

* DOCSUP-1350 (#128)

* edited EN version

* add EN and RU translation

* minor changes

* CLICKHOUSEDOCS-635: Updated the description.

Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Evgenia Sudarikova <[email protected]>

* Fix tests.

* Better PVS image

* DOCS-605: Description for the always_fetch_merged_part setting (#11921)

* Revolg DOCSUP-998 Document the always_fetch_merged_part setting (#123)

* Add always_fetch_merged_part setting

* revolg-DOCSUP-998-add_always_fetch_merged_part_setting link fixed

* Apply suggestions from code review

Co-authored-by: BayoNet <[email protected]>

* Add always_fetch_merged_part setting. Updates.

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* Add always_fetch_merged_part setting. Updates.

Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-605: Minor fixes.

* CLICKHOUSEDOCS-605: Added Plausible to Adopters.

* Update docs/ru/operations/settings/settings.md

Co-authored-by: alesapin <[email protected]>

* Update docs/en/operations/settings/settings.md

Co-authored-by: alesapin <[email protected]>

* CLICKHOUSEDOCS-605: Fixed access rights description.

Co-authored-by: olgarev <[email protected]>
Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: alesapin <[email protected]>

* Update Dockerfile

* revert e9d3c48

* [blog] 'Package Repository Behind CDN' post (#12082)

* support iframes from DataLens

* initial blog post text

* Improve REVOKE command: now it requires only grant/admin option for only
access which will be revoked.
REVOKE ALL FROM user1 now revokes all granted roles.

* Fix limiting the number of threads for VIEW.

* Update tips.md

* Added test.

* Remove pvs studio from images list

* Better shutdown and conversion

* Reverse arguments

* Fix result_rows and result_bytes metrics for selects.

* Fix result_rows and result_bytes metrics for selects.

* improve breadcrumbs markup

* Fix tests.

* fix segfault with -StateResample combinators

* Less race conditions

* [docker] install ca-certificates before the first apt-get update (#12095)

* [docker] install ca-certificates before first apt-get update

* Update Dockerfile

* DOCS-522: max_parser_depth (#12097)

* asiana21-DOCSUP-925-max_parser_depth (#132)

* docs(max_parser_depth): added the setting description

* docs(max_parser_depth): some changes

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* docs(max_parser_depth): added ru translation

* docs(max_parser_depth): removed quotation marks

Co-authored-by: asiana21 <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-522: Fixed the link.

Co-authored-by: AsiaKorushkina <[email protected]>
Co-authored-by: asiana21 <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>

* Rewrite curl dependency in a more ch compatible way

- add support of unbundled curl
- add CURL::libcurl libraries
- avoid explicit linkage of daemon with curl (added with sentry)
- set CACHE variables for non-direct users:
  - mariadb-connector-c
  - aws-s3-cmake
  - sentry-native

Cc: @alexey-milovidov
Cc: @alesapin (requires docker image update)
Cc: @abyss7

Refs: #11300
Refs: #8011
Refs: #8905

v2: replace cmake/find/curl.cmake with proper contrib/curl-cmake (as
pointed by @abyss7, cmake/find/*.cmake is deprecated)

* Added results for AWS Lightsail

* (typo) in doc (#12099)

* Added test.

* Create codeql-analysis.yml

* Tiny fixes

* Create anchore-analysis.yml

* Changelog for 20.5

* Update CHANGELOG.md

* Update README.md

* Fix test (#12088)

* Test for a fixed issue #10668, related to input_format_allow_errors_num in CSV

* Add unbundled mode flag

* Remove LC converting to Arrow.

* Remove LC converting to Arrow.

* Move skip lists to clickhouse-test

* Remove LC converting to Arrow.

* More verbose message about skip

* Make skip-list optional

* Added test.

* Add type column in system.disks

* Update clickhouse-test

* Fix handling dependency of table with ENGINE=Dictionary on dictionary.

* Add test.

* Update 01355_CSV_input_format_allow_errors.sh

* Update CHANGELOG.md

* Added a showcase of minimal Docker image

* Added a comment

* Added a comment

* Added a comment

* Formatting

* contrib/unixodbc-cmake: Fix build when UNBUNDLED

target_compile_definitions may only set INTERFACE properties on IMPORTED targets

* Fix version column in replicated version collapsing merge tree (#12121)

* poco-cmake: Fix Poco::Data::ODBC target when UNBUNDLED

By default IMPORTED target has a scope in the directory in which it is created
and below. This leads to the following issues when building UNBUNDLED:

Target "clickhouse" links to target "Poco::Data::ODBC" but the target was not
found.  Perhaps a find_package() call is missing for an IMPORTED target, or an
ALIAS target is missing?

* Add missed <atomic> include in ProxyListConfiguration

* Improve performace of reading in order of sorting key. (#11696)

* simplify reading in order of sorting key

* add perf test for reading many parts

* Revert "simplify reading in order of sorting key"

This reverts commit 7267d7c.

* add threshold for preliminary merge for reading in order

* better threshold

* limit threads in test

* Do not enable sentry if ENABLE_LIBRARIES is not set

* Fail if curl library was enabled and was not found in case of unbundled build

* Normalize "pid" file handling #3501

* Update StatusFile.cpp

* New ISO8601 year modificators for formatDateTime

* Added a test

* Include libcurl4-openssl-dev into yandex/clickhouse-deb-builder

* Remove harmful code from "geoDistance" #12117

* Update formatDateTime.cpp

* Fix warnings from CodeQL

* Added a test

* Minor modification

* Update libdivide to the latest master

* Replace exit to abort in libdivide

* Fix potential overflow in integer division #12119

* Added a test

* Whitespace

* Added a test for #4211

* Attempt to fix "Arcadia" build

* Rename test

* Update arraySum.cpp

* Make code clearer: use enum instead of `bool internal`.

* Update StorageDictionary.h

* Update StorageDictionary.h

* ILIKE operator (#12125)

* Integrated CachingAllocator into MarkCache

* fixed build errors

* reset func hotfix

* upd: Fixing build

* updated submodules links

* fix 2

* updating grabber allocator proto

* updating lost work

* updating CMake to use concepts

* some other changes to get it building (integration into MarkCache)

* further integration into caches

* updated Async metrics, fixed some build errors

* and some other errors revealing

* added perfect forwarding to some functions

* fix: forward template

* fix: constexpr modifier

* fix: FakePODAllocator missing member func

* updated PODArray constructor taking alloc params

* fix: PODArray overload with n restored

* fix: FakePODAlloc duplicating alloc() func

* added constexpr variable for alloc_tag_t

* split cache values by allocators, provided updates

* fix: memcpy

* fix: constexpr modifier

* fix: noexcept modifier

* fix: alloc_tag_t for PODArray constructor

* fix: PODArray copy ctor with different alloc

* fix: resize() signature

* updating to lastest working master

* syncing with 273267

* first draft version

* fix: update Searcher to case-insensitive

* added ILIKE test

* fixed style errors, updated test, split like and ilike,  added notILike

* replaced inconsistent comments

* fixed show tables ilike

* updated missing test cases

* regenerated ya.make

* Update 01355_ilike.sql

Co-authored-by: myrrc <[email protected]>
Co-authored-by: alexey-milovidov <[email protected]>

* add parseDateTimeBestEffortUS function (#12028)

* add function parseDateTimeBestEffortUS
* add test
* add doc

Co-authored-by: alexey-milovidov <[email protected]>

* Cleanup changelog (half done). Now it is acceptable #12104

* Cleanup changelog (half done). Now it is more acceptable #12104

* Cleanup changelog (half done). Now it is more acceptable #12104

* Cleanup changelog (half done). Additions requested by @filimonov #12104

* fix segfault with -StateResample combinators

* Whitespace

* Style

Co-authored-by: Nikolai Kochetov <[email protected]>
Co-authored-by: Ivan Blinkov <[email protected]>
Co-authored-by: Alexander Kuzmenkov <[email protected]>
Co-authored-by: alesapin <[email protected]>
Co-authored-by: BayoNet <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Roman Bug <[email protected]>
Co-authored-by: romanzhukov <[email protected]>
Co-authored-by: kssenii <[email protected]>
Co-authored-by: tavplubix <[email protected]>
Co-authored-by: Alexander Kuzmenkov <[email protected]>
Co-authored-by: Ivan <[email protected]>
Co-authored-by: Vitaly Baranov <[email protected]>
Co-authored-by: alexey-milovidov <[email protected]>
Co-authored-by: Nikita Mikhaylov <[email protected]>
Co-authored-by: Azat Khuzhin <[email protected]>
Co-authored-by: chengy8934 <[email protected]>
Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
Co-authored-by: MicrochipQ <[email protected]>
Co-authored-by: Artem Zuikov <[email protected]>
Co-authored-by: Alexander Kazakov <[email protected]>
Co-authored-by: Vladimir Chebotarev <[email protected]>
Co-authored-by: Nicolae Vartolomei <[email protected]>
Co-authored-by: filimonov <[email protected]>
Co-authored-by: olgarev <[email protected]>
Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: AsiaKorushkina <[email protected]>
Co-authored-by: asiana21 <[email protected]>
Co-authored-by: BohuTANG <[email protected]>
Co-authored-by: zhang2014 <[email protected]>
Co-authored-by: Evgenia Sudarikova <[email protected]>
Co-authored-by: Anton Popov <[email protected]>
Co-authored-by: manmitya <[email protected]>
Co-authored-by: Nikolai Kochetov <[email protected]>
Co-authored-by: Mikhail Filimonov <[email protected]>
Co-authored-by: Anton Ivashkin <[email protected]>
Co-authored-by: Ilya Yatsishin <[email protected]>
Co-authored-by: tavplubix <[email protected]>
Co-authored-by: Matwey V. Kornilov <[email protected]>
Co-authored-by: vivarum <[email protected]>
Co-authored-by: myrrc <[email protected]>
Co-authored-by: myrrc <[email protected]>
Co-authored-by: flynn <[email protected]>
alexey-milovidov added a commit that referenced this pull request Jul 7, 2020
* Fix typos

* Added a test for #8550

* Update extended-roadmap.md

* Update test

* Fix FPE, step 1

* Make it more correct

* Add a test

* Avoid floating point error in geohashesInBox #11369

* Avro: allow missing fields

* update

* Fix build

* Revert "[experiment] maybe fix warnings in integration tests"

* Add xeus-clickhouse (#12010)

xeus-clickhouse is a Jupyter kernal for ClickHouse

* Fix test

* Fix array size overflow in generateRandom

* Added a test

* Update ErrorCodes.cpp

* More hardening

* More hardening

* Move reading from RabbitMQ into background task

* Fix access rights: cannot grant DDL when allow_ddl=0

* Add tests

* Add test test_allow_ddl.

* Added failing test

* Remove the usage of obsolete setting

* Whitespace

* Added a test

* Allow to ALTER partition key in some cases

* Slightly more safe

* Only allow Enum extension within the same width

* Update test

* Added failing test for Replicated table

* Fix clang-tidy

* Whitespace

* Write partition key changes to ZooKeeper

* Typos

* Implement for ReplicatedMergeTree

* Added test reference

* Added missing ORDER BY in test

* Fix integration test

* Fix error in addMonths with floating point argument

* Fix error in addMonths with floating point argument

* Fix overflow in function "neighbor"

* Whitespace

* Whitespace

* Fix ORDER BY tuple with COLLATE on const column

* clickhouse-local: logging flags fixes

* clickhouse-local: use std::filesystem::equivalent

* Limit /proc/cpuinfo metrics to linux only

* Feature 8074 (#12014)

* refs #8074 1: start to stream

* refs final check format and spell

* refs final check format and spell

* refs #8074 fix up link to sql-reference/functions/other-functions

* Bump idna from 2.9 to 2.10 in /docs/tools

Bumps [idna](https://github.com/kjd/idna) from 2.9 to 2.10.
- [Release notes](https://github.com/kjd/idna/releases)
- [Changelog](https://github.com/kjd/idna/blob/master/HISTORY.rst)
- [Commits](kjd/idna@v2.9...v2.10)

Signed-off-by: dependabot-preview[bot] <[email protected]>

* make a short test for DateTime

* Fixup

* DOCS-636 Synchronized some edits from EN to RU (#11941)

* [review][clickhousedocs][translate] DOCSUP-1351: Edit and translate to Russian (#129)

* DOCSUP-1351: Add blockSerializedSize (RU)

* DOCSUP-1351: Fix blockSerializedSize description by function description template.

* DOCSUP-1351: PR8756- Update Distributed engine section.

* DOCSUP-1351: PR9076-Show Queries more like MySQL did.

* DOCSUP-1351: PR#9919-system.tables improvements (total_rows/total_bytes/storage_policy)

* DOCSUP-1351: (ru) blockSerializedSize remake by template.

* DOCSUP-1351: PR#9598-Add function arrayReduceInRange and update arrayReduce function.

* DOCSUP-1351: PR#9598 Fix arrayReduce and arrayReduceInRanges sections by template.

* DOCSUP-1351: Some fixes.

* DOCSUP-1351: Some fixes.

Co-authored-by: romanzhukov <[email protected]>

* CLICKHOUSEDOCS-636: Minor changes.

Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Roman Bug <[email protected]>
Co-authored-by: romanzhukov <[email protected]>

* Use ConcurentBoundedQueue instead of vector

* Temporary enable debug logs when releasing docs

* Better docker images list

* [docs] improve stable releases discovery

* Update contrib/jemalloc-cmake/CMakeLists.txt

* Remove libevent library

* Automated backporting machinery (#12029)

* Add automated cherry-pick machinery

* Added script for backporting machinery

* Implement dry-run mode

* Comment old methods

* Fix python2

* Add ya.make for sandbox tasks

* Remove old stuff

* Move writing to RabbitMQ into background task

* Add TLB misses perf counters.

* Update ThreadProfileEvents.cpp

* Fake change in dockerfile

* Fix tuple nullable comparison.

* Fix access rights: cannot grant INTROSPECTION when allow_introspection_functions=0.

* fixup

* Update ThreadProfileEvents.cpp

* Fix test.

* Added test.

* Fix and simplify code

* Fix test.

* Update ITransformingStep.h

* Fix "Sharding key is not deterministic" message

* Do not check *optimize_skip_unused_shards_nesting w/o *optimize_skip_unused_shards

This will avoid supperior log message in case of
*optimize_skip_unused_shards_nesting already disables it.
And also it is logical.

* Remove test that is not supported by "Arcadia" build system

* Make topK return Enum for Enum types

* parse metadata in parallel when loading tables

* Fix build

* fixup

* Update ThreadProfileEvents.cpp

* Update browse-code.md (#12047)

* Update browse-code.md

纠正了一些翻译错误。

* Update browse-code.md

Co-authored-by: Ivan Blinkov <[email protected]>

* Bump python-slugify from 1.2.6 to 4.0.1 in /docs/tools

Bumps [python-slugify](https://github.com/un33k/python-slugify) from 1.2.6 to 4.0.1.
- [Release notes](https://github.com/un33k/python-slugify/releases)
- [Changelog](https://github.com/un33k/python-slugify/blob/master/CHANGELOG.md)
- [Commits](un33k/python-slugify@1.2.6...4.0.1)

Signed-off-by: dependabot-preview[bot] <[email protected]>

* Update ThreadProfileEvents.cpp

* Update README.md

* Fix typo (#12046)

* Fix test_allow_introspection.

* Try fix labda tuple(LC) argument.

* Test image changes

* Try fix labda tuple(LC) argument.

* Add pvs studio to images

* Added test.

* fix low card types in merge join (#12035)

* Update contrib/poco to ClickHouse-Extras/poco #22 (#12037)

* Updated ClickHouse-Extras/poco #22

* Fix defaultValueOfArgumentType

* Added test.

* Update cpu_synthetic.xml

* Moves task shall be started if new storage policy needs them.

* Added test for automatic start of background move task.

* Add ability to run any image version from packager and runner

* Check type of filter for prewhere.

* Check type of filter for prewhere.

* Check type of filter for prewhere.

* Check type of filter for prewhere.

* Added test.

* Try fix pk in tuple performance

Possible approach for fixing #10574

The problem is that prepared sets are built correctly, it is a hash map of key -> set
where key is a hash of AST and list of data types (when we a list of
tuples of literals).

However, when the key is built from the index to try and find if there
exists a prepared set that would match it looks for data types of the
primary key (see how data_types is populated) because the primary key
has only one field (v in my example) it can not find the prepared set.

The patch looks for any prepared indexes where data types match for the
subset of fields found in primary key, we are not interested in other
fields anyway for the purpose of primary key pruning.

* Fix partial revokes (complex cases).

* Changelog for 20.3.11, 12

* simple changelog script

* bump CI

* Fix tests.

* Add explicit test for a case where AST hashes collide for different prepared sets

* [blog] add RSS feed (#12064)

* [blog] add rss feed

* better title

* Update CHANGELOG.md

Co-authored-by: Ivan Blinkov <[email protected]>

* bump ci

* Moved useless S3 logging to TRACE level.

* Add a test to cover non-const tuple elemenets (just in case)

* Bump

* Update query-complexity.md

Remove a note about read limits applied on threads level.

* Update query-complexity.md

* Update query-complexity.md

* Update query-complexity.md

* DOCS-609: max_server_memory_usage (#11771)

* Revolg DOCSUP-1000 add max server memory usage setting (#125)

* Add max_server_memory_usage setting, delete max_memory_usage_for_all_queries setting.

* Syntax fixed

* Apply suggestions from code review

Co-authored-by: BayoNet <[email protected]>

* Doc for the max_server_memory_usage setting. Updates.

Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-609: Minor fixes.

* CLICKHOUSEDOCS-609: Actualized position of the setting.

Co-authored-by: olgarev <[email protected]>
Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>

* Add force_primary_key to a pk in tuple test

* DOCS-510: runningAccumulate (#12061)

* asiana21-DOCSUP-797 (#117)

* docs(runningAccumulate): the function description is added

* docs(runningAccumulate): the function description is modified

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* docs(runningAccumulate): some changes

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* docs(runningAccumulate): added ru translation

Co-authored-by: asiana21 <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-510: Minor fix.

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: Ivan Blinkov <[email protected]>

* CLICKHOUSEDOCS-510: Fixed links.

Co-authored-by: AsiaKorushkina <[email protected]>
Co-authored-by: asiana21 <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Ivan Blinkov <[email protected]>

* Remove const specifier to allow auto-move (clangtidy)

* Rewrite Set lookup to make it more readable

* [docs] Sync zh/development/build-osx.md from EN (#12071)

* ISSUES-4006 support first for ALTER ADD|MODIFY COLUMN

* Update deb image

* Don't download image twice

* Remove garbage from images

* bump ci

* fixup

* DOCS-635: Translated the EN version of the AvroConfluent format description (#11930)

* DOCSUP-1350 (#128)

* edited EN version

* add EN and RU translation

* minor changes

* CLICKHOUSEDOCS-635: Updated the description.

Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Evgenia Sudarikova <[email protected]>

* Fix tests.

* Better PVS image

* DOCS-605: Description for the always_fetch_merged_part setting (#11921)

* Revolg DOCSUP-998 Document the always_fetch_merged_part setting (#123)

* Add always_fetch_merged_part setting

* revolg-DOCSUP-998-add_always_fetch_merged_part_setting link fixed

* Apply suggestions from code review

Co-authored-by: BayoNet <[email protected]>

* Add always_fetch_merged_part setting. Updates.

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* Add always_fetch_merged_part setting. Updates.

Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-605: Minor fixes.

* CLICKHOUSEDOCS-605: Added Plausible to Adopters.

* Update docs/ru/operations/settings/settings.md

Co-authored-by: alesapin <[email protected]>

* Update docs/en/operations/settings/settings.md

Co-authored-by: alesapin <[email protected]>

* CLICKHOUSEDOCS-605: Fixed access rights description.

Co-authored-by: olgarev <[email protected]>
Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: alesapin <[email protected]>

* Update Dockerfile

* revert e9d3c48

* [blog] 'Package Repository Behind CDN' post (#12082)

* support iframes from DataLens

* initial blog post text

* Improve REVOKE command: now it requires only grant/admin option for only
access which will be revoked.
REVOKE ALL FROM user1 now revokes all granted roles.

* Fix limiting the number of threads for VIEW.

* Update tips.md

* Added test.

* Remove pvs studio from images list

* Better shutdown and conversion

* Reverse arguments

* Fix result_rows and result_bytes metrics for selects.

* Fix result_rows and result_bytes metrics for selects.

* improve breadcrumbs markup

* Fix tests.

* Less race conditions

* [docker] install ca-certificates before the first apt-get update (#12095)

* [docker] install ca-certificates before first apt-get update

* Update Dockerfile

* DOCS-522: max_parser_depth (#12097)

* asiana21-DOCSUP-925-max_parser_depth (#132)

* docs(max_parser_depth): added the setting description

* docs(max_parser_depth): some changes

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* docs(max_parser_depth): added ru translation

* docs(max_parser_depth): removed quotation marks

Co-authored-by: asiana21 <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-522: Fixed the link.

Co-authored-by: AsiaKorushkina <[email protected]>
Co-authored-by: asiana21 <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>

* Added results for AWS Lightsail

* (typo) in doc (#12099)

* Added test.

* Create codeql-analysis.yml

* Tiny fixes

* Create anchore-analysis.yml

* Update README.md

* Fix test (#12088)

* Test for a fixed issue #10668, related to input_format_allow_errors_num in CSV

* Add unbundled mode flag

* Remove LC converting to Arrow.

* Remove LC converting to Arrow.

* Move skip lists to clickhouse-test

* Remove LC converting to Arrow.

* More verbose message about skip

* Make skip-list optional

* Added test.

* Update clickhouse-test

* Update 01355_CSV_input_format_allow_errors.sh

* Added a showcase of minimal Docker image

* Added a comment

* Added a comment

* Added a comment

* Formatting

* contrib/unixodbc-cmake: Fix build when UNBUNDLED

target_compile_definitions may only set INTERFACE properties on IMPORTED targets

* Fix version column in replicated version collapsing merge tree (#12121)

* poco-cmake: Fix Poco::Data::ODBC target when UNBUNDLED

By default IMPORTED target has a scope in the directory in which it is created
and below. This leads to the following issues when building UNBUNDLED:

Target "clickhouse" links to target "Poco::Data::ODBC" but the target was not
found.  Perhaps a find_package() call is missing for an IMPORTED target, or an
ALIAS target is missing?

* Improve performace of reading in order of sorting key. (#11696)

* simplify reading in order of sorting key

* add perf test for reading many parts

* Revert "simplify reading in order of sorting key"

This reverts commit 7267d7c.

* add threshold for preliminary merge for reading in order

* better threshold

* limit threads in test

* Normalize "pid" file handling #3501

* Update StatusFile.cpp

Co-authored-by: Alexey Milovidov <[email protected]>
Co-authored-by: Andrew Onyshchuk <[email protected]>
Co-authored-by: feng lv <[email protected]>
Co-authored-by: alesapin <[email protected]>
Co-authored-by: Wang Fenjin <[email protected]>
Co-authored-by: kssenii <[email protected]>
Co-authored-by: Vitaly Baranov <[email protected]>
Co-authored-by: Mikhail Gaidamaka <[email protected]>
Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
Co-authored-by: Alexander Kuzmenkov <[email protected]>
Co-authored-by: Nikolai Kochetov <[email protected]>
Co-authored-by: Ivan Blinkov <[email protected]>
Co-authored-by: BayoNet <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Roman Bug <[email protected]>
Co-authored-by: romanzhukov <[email protected]>
Co-authored-by: tavplubix <[email protected]>
Co-authored-by: Alexander Kuzmenkov <[email protected]>
Co-authored-by: Ivan <[email protected]>
Co-authored-by: Nikita Mikhaylov <[email protected]>
Co-authored-by: Azat Khuzhin <[email protected]>
Co-authored-by: chengy8934 <[email protected]>
Co-authored-by: MicrochipQ <[email protected]>
Co-authored-by: Artem Zuikov <[email protected]>
Co-authored-by: Alexander Kazakov <[email protected]>
Co-authored-by: Vladimir Chebotarev <[email protected]>
Co-authored-by: Nicolae Vartolomei <[email protected]>
Co-authored-by: filimonov <[email protected]>
Co-authored-by: olgarev <[email protected]>
Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: AsiaKorushkina <[email protected]>
Co-authored-by: asiana21 <[email protected]>
Co-authored-by: BohuTANG <[email protected]>
Co-authored-by: zhang2014 <[email protected]>
Co-authored-by: Evgenia Sudarikova <[email protected]>
Co-authored-by: Anton Popov <[email protected]>
Co-authored-by: manmitya <[email protected]>
Co-authored-by: Nikolai Kochetov <[email protected]>
Co-authored-by: Mikhail Filimonov <[email protected]>
Co-authored-by: Ilya Yatsishin <[email protected]>
Co-authored-by: tavplubix <[email protected]>
Co-authored-by: Matwey V. Kornilov <[email protected]>
alexey-milovidov added a commit that referenced this pull request Jul 7, 2020
… selects. (#12239)

* performance comparison

* Add integration test for MySQL enums type

* Fix bad log message at server startup

* Insert enum column values for test

* Better diagnostics of "Replica {} appears to be already active" message

* Fix typos

* Added a test for #8550

* Update extended-roadmap.md

* Update test

* Fix FPE, step 1

* Make it more correct

* Add a test

* Avoid floating point error in geohashesInBox #11369

* Avro: allow missing fields

* update

* Fix build

* Revert "[experiment] maybe fix warnings in integration tests"

* Add xeus-clickhouse (#12010)

xeus-clickhouse is a Jupyter kernal for ClickHouse

* Fix test

* Fix array size overflow in generateRandom

* Added a test

* Update ErrorCodes.cpp

* More hardening

* More hardening

* Move reading from RabbitMQ into background task

* Fix access rights: cannot grant DDL when allow_ddl=0

* Add tests

* Add test test_allow_ddl.

* Added failing test

* Remove the usage of obsolete setting

* Whitespace

* Added a test

* Allow to ALTER partition key in some cases

* Slightly more safe

* Only allow Enum extension within the same width

* Update test

* Added failing test for Replicated table

* Fix clang-tidy

* Whitespace

* Write partition key changes to ZooKeeper

* Typos

* Implement for ReplicatedMergeTree

* Added test reference

* Added missing ORDER BY in test

* Fix integration test

* Fix error in addMonths with floating point argument

* Fix error in addMonths with floating point argument

* Fix overflow in function "neighbor"

* Whitespace

* Whitespace

* Fix ORDER BY tuple with COLLATE on const column

* clickhouse-local: logging flags fixes

* clickhouse-local: use std::filesystem::equivalent

* Limit /proc/cpuinfo metrics to linux only

* Feature 8074 (#12014)

* refs #8074 1: start to stream

* refs final check format and spell

* refs final check format and spell

* refs #8074 fix up link to sql-reference/functions/other-functions

* Bump idna from 2.9 to 2.10 in /docs/tools

Bumps [idna](https://github.com/kjd/idna) from 2.9 to 2.10.
- [Release notes](https://github.com/kjd/idna/releases)
- [Changelog](https://github.com/kjd/idna/blob/master/HISTORY.rst)
- [Commits](kjd/idna@v2.9...v2.10)

Signed-off-by: dependabot-preview[bot] <[email protected]>

* make a short test for DateTime

* Fixup

* DOCS-636 Synchronized some edits from EN to RU (#11941)

* [review][clickhousedocs][translate] DOCSUP-1351: Edit and translate to Russian (#129)

* DOCSUP-1351: Add blockSerializedSize (RU)

* DOCSUP-1351: Fix blockSerializedSize description by function description template.

* DOCSUP-1351: PR8756- Update Distributed engine section.

* DOCSUP-1351: PR9076-Show Queries more like MySQL did.

* DOCSUP-1351: PR#9919-system.tables improvements (total_rows/total_bytes/storage_policy)

* DOCSUP-1351: (ru) blockSerializedSize remake by template.

* DOCSUP-1351: PR#9598-Add function arrayReduceInRange and update arrayReduce function.

* DOCSUP-1351: PR#9598 Fix arrayReduce and arrayReduceInRanges sections by template.

* DOCSUP-1351: Some fixes.

* DOCSUP-1351: Some fixes.

Co-authored-by: romanzhukov <[email protected]>

* CLICKHOUSEDOCS-636: Minor changes.

Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Roman Bug <[email protected]>
Co-authored-by: romanzhukov <[email protected]>

* Use ConcurentBoundedQueue instead of vector

* Temporary enable debug logs when releasing docs

* Better docker images list

* [docs] improve stable releases discovery

* Update contrib/jemalloc-cmake/CMakeLists.txt

* Remove libevent library

* Automated backporting machinery (#12029)

* Add automated cherry-pick machinery

* Added script for backporting machinery

* Implement dry-run mode

* Comment old methods

* Fix python2

* Add ya.make for sandbox tasks

* Remove old stuff

* Move writing to RabbitMQ into background task

* Add TLB misses perf counters.

* Update ThreadProfileEvents.cpp

* Fake change in dockerfile

* Fix tuple nullable comparison.

* Fix access rights: cannot grant INTROSPECTION when allow_introspection_functions=0.

* fixup

* Update ThreadProfileEvents.cpp

* Fix test.

* Added test.

* Fix and simplify code

* Fix test.

* Update ITransformingStep.h

* Fix "Sharding key is not deterministic" message

* Do not check *optimize_skip_unused_shards_nesting w/o *optimize_skip_unused_shards

This will avoid supperior log message in case of
*optimize_skip_unused_shards_nesting already disables it.
And also it is logical.

* Remove test that is not supported by "Arcadia" build system

* Make topK return Enum for Enum types

* parse metadata in parallel when loading tables

* Fix build

* fixup

* Update ThreadProfileEvents.cpp

* Update browse-code.md (#12047)

* Update browse-code.md

纠正了一些翻译错误。

* Update browse-code.md

Co-authored-by: Ivan Blinkov <[email protected]>

* Bump python-slugify from 1.2.6 to 4.0.1 in /docs/tools

Bumps [python-slugify](https://github.com/un33k/python-slugify) from 1.2.6 to 4.0.1.
- [Release notes](https://github.com/un33k/python-slugify/releases)
- [Changelog](https://github.com/un33k/python-slugify/blob/master/CHANGELOG.md)
- [Commits](un33k/python-slugify@1.2.6...4.0.1)

Signed-off-by: dependabot-preview[bot] <[email protected]>

* Update ThreadProfileEvents.cpp

* Update README.md

* Fix typo (#12046)

* Fix test_allow_introspection.

* Try fix labda tuple(LC) argument.

* Test image changes

* Try fix labda tuple(LC) argument.

* Add pvs studio to images

* Added test.

* fix low card types in merge join (#12035)

* Update contrib/poco to ClickHouse-Extras/poco #22 (#12037)

* Updated ClickHouse-Extras/poco #22

* Fix defaultValueOfArgumentType

* Added test.

* Update cpu_synthetic.xml

* Moves task shall be started if new storage policy needs them.

* Added test for automatic start of background move task.

* Add ability to run any image version from packager and runner

* Try fix pk in tuple performance

Possible approach for fixing #10574

The problem is that prepared sets are built correctly, it is a hash map of key -> set
where key is a hash of AST and list of data types (when we a list of
tuples of literals).

However, when the key is built from the index to try and find if there
exists a prepared set that would match it looks for data types of the
primary key (see how data_types is populated) because the primary key
has only one field (v in my example) it can not find the prepared set.

The patch looks for any prepared indexes where data types match for the
subset of fields found in primary key, we are not interested in other
fields anyway for the purpose of primary key pruning.

* Fix partial revokes (complex cases).

* Changelog for 20.3.11, 12

* simple changelog script

* bump CI

* Add explicit test for a case where AST hashes collide for different prepared sets

* [blog] add RSS feed (#12064)

* [blog] add rss feed

* better title

* Update CHANGELOG.md

Co-authored-by: Ivan Blinkov <[email protected]>

* bump ci

* Moved useless S3 logging to TRACE level.

* Add a test to cover non-const tuple elemenets (just in case)

* Bump

* Update query-complexity.md

Remove a note about read limits applied on threads level.

* Update query-complexity.md

* Update query-complexity.md

* Update query-complexity.md

* DOCS-609: max_server_memory_usage (#11771)

* Revolg DOCSUP-1000 add max server memory usage setting (#125)

* Add max_server_memory_usage setting, delete max_memory_usage_for_all_queries setting.

* Syntax fixed

* Apply suggestions from code review

Co-authored-by: BayoNet <[email protected]>

* Doc for the max_server_memory_usage setting. Updates.

Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-609: Minor fixes.

* CLICKHOUSEDOCS-609: Actualized position of the setting.

Co-authored-by: olgarev <[email protected]>
Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>

* Add force_primary_key to a pk in tuple test

* DOCS-510: runningAccumulate (#12061)

* asiana21-DOCSUP-797 (#117)

* docs(runningAccumulate): the function description is added

* docs(runningAccumulate): the function description is modified

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* docs(runningAccumulate): some changes

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* docs(runningAccumulate): added ru translation

Co-authored-by: asiana21 <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-510: Minor fix.

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: Ivan Blinkov <[email protected]>

* CLICKHOUSEDOCS-510: Fixed links.

Co-authored-by: AsiaKorushkina <[email protected]>
Co-authored-by: asiana21 <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Ivan Blinkov <[email protected]>

* Remove const specifier to allow auto-move (clangtidy)

* Rewrite Set lookup to make it more readable

* [docs] Sync zh/development/build-osx.md from EN (#12071)

* ISSUES-4006 support first for ALTER ADD|MODIFY COLUMN

* Update deb image

* Don't download image twice

* Remove garbage from images

* bump ci

* fixup

* DOCS-635: Translated the EN version of the AvroConfluent format description (#11930)

* DOCSUP-1350 (#128)

* edited EN version

* add EN and RU translation

* minor changes

* CLICKHOUSEDOCS-635: Updated the description.

Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Evgenia Sudarikova <[email protected]>

* Better PVS image

* DOCS-605: Description for the always_fetch_merged_part setting (#11921)

* Revolg DOCSUP-998 Document the always_fetch_merged_part setting (#123)

* Add always_fetch_merged_part setting

* revolg-DOCSUP-998-add_always_fetch_merged_part_setting link fixed

* Apply suggestions from code review

Co-authored-by: BayoNet <[email protected]>

* Add always_fetch_merged_part setting. Updates.

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* Add always_fetch_merged_part setting. Updates.

Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-605: Minor fixes.

* CLICKHOUSEDOCS-605: Added Plausible to Adopters.

* Update docs/ru/operations/settings/settings.md

Co-authored-by: alesapin <[email protected]>

* Update docs/en/operations/settings/settings.md

Co-authored-by: alesapin <[email protected]>

* CLICKHOUSEDOCS-605: Fixed access rights description.

Co-authored-by: olgarev <[email protected]>
Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: alesapin <[email protected]>

* Update Dockerfile

* revert e9d3c48

* [blog] 'Package Repository Behind CDN' post (#12082)

* support iframes from DataLens

* initial blog post text

* Improve REVOKE command: now it requires only grant/admin option for only
access which will be revoked.
REVOKE ALL FROM user1 now revokes all granted roles.

* Fix limiting the number of threads for VIEW.

* Update tips.md

* Added test.

* Remove pvs studio from images list

* Better shutdown and conversion

* Reverse arguments

* Fix result_rows and result_bytes metrics for selects.

* Fix result_rows and result_bytes metrics for selects.

* improve breadcrumbs markup

* Less race conditions

* [docker] install ca-certificates before the first apt-get update (#12095)

* [docker] install ca-certificates before first apt-get update

* Update Dockerfile

* DOCS-522: max_parser_depth (#12097)

* asiana21-DOCSUP-925-max_parser_depth (#132)

* docs(max_parser_depth): added the setting description

* docs(max_parser_depth): some changes

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* docs(max_parser_depth): added ru translation

* docs(max_parser_depth): removed quotation marks

Co-authored-by: asiana21 <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-522: Fixed the link.

Co-authored-by: AsiaKorushkina <[email protected]>
Co-authored-by: asiana21 <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>

* Added results for AWS Lightsail

* (typo) in doc (#12099)

* Added test.

* Create codeql-analysis.yml

* Tiny fixes

* Create anchore-analysis.yml

* Update README.md

* Fix test (#12088)

* Test for a fixed issue #10668, related to input_format_allow_errors_num in CSV

* Add unbundled mode flag

* Remove LC converting to Arrow.

* Remove LC converting to Arrow.

* Move skip lists to clickhouse-test

* Remove LC converting to Arrow.

* More verbose message about skip

* Make skip-list optional

* Added test.

* Update clickhouse-test

* Update 01355_CSV_input_format_allow_errors.sh

* Added a showcase of minimal Docker image

* Added a comment

* Added a comment

* Added a comment

* Formatting

* contrib/unixodbc-cmake: Fix build when UNBUNDLED

target_compile_definitions may only set INTERFACE properties on IMPORTED targets

* Fix version column in replicated version collapsing merge tree (#12121)

* poco-cmake: Fix Poco::Data::ODBC target when UNBUNDLED

By default IMPORTED target has a scope in the directory in which it is created
and below. This leads to the following issues when building UNBUNDLED:

Target "clickhouse" links to target "Poco::Data::ODBC" but the target was not
found.  Perhaps a find_package() call is missing for an IMPORTED target, or an
ALIAS target is missing?

* Improve performace of reading in order of sorting key. (#11696)

* simplify reading in order of sorting key

* add perf test for reading many parts

* Revert "simplify reading in order of sorting key"

This reverts commit 7267d7c.

* add threshold for preliminary merge for reading in order

* better threshold

* limit threads in test

* Normalize "pid" file handling #3501

* Update StatusFile.cpp

Co-authored-by: Alexander Kuzmenkov <[email protected]>
Co-authored-by: BohuTANG <[email protected]>
Co-authored-by: Nikita Mikhaylov <[email protected]>
Co-authored-by: Alexey Milovidov <[email protected]>
Co-authored-by: Andrew Onyshchuk <[email protected]>
Co-authored-by: feng lv <[email protected]>
Co-authored-by: alesapin <[email protected]>
Co-authored-by: Wang Fenjin <[email protected]>
Co-authored-by: kssenii <[email protected]>
Co-authored-by: Vitaly Baranov <[email protected]>
Co-authored-by: Mikhail Gaidamaka <[email protected]>
Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
Co-authored-by: Nikolai Kochetov <[email protected]>
Co-authored-by: Ivan Blinkov <[email protected]>
Co-authored-by: BayoNet <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Roman Bug <[email protected]>
Co-authored-by: romanzhukov <[email protected]>
Co-authored-by: tavplubix <[email protected]>
Co-authored-by: Alexander Kuzmenkov <[email protected]>
Co-authored-by: Ivan <[email protected]>
Co-authored-by: Azat Khuzhin <[email protected]>
Co-authored-by: chengy8934 <[email protected]>
Co-authored-by: MicrochipQ <[email protected]>
Co-authored-by: Artem Zuikov <[email protected]>
Co-authored-by: Alexander Kazakov <[email protected]>
Co-authored-by: Vladimir Chebotarev <[email protected]>
Co-authored-by: Nicolae Vartolomei <[email protected]>
Co-authored-by: filimonov <[email protected]>
Co-authored-by: olgarev <[email protected]>
Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: AsiaKorushkina <[email protected]>
Co-authored-by: asiana21 <[email protected]>
Co-authored-by: zhang2014 <[email protected]>
Co-authored-by: Evgenia Sudarikova <[email protected]>
Co-authored-by: Anton Popov <[email protected]>
Co-authored-by: manmitya <[email protected]>
Co-authored-by: Nikolai Kochetov <[email protected]>
Co-authored-by: Mikhail Filimonov <[email protected]>
Co-authored-by: Ilya Yatsishin <[email protected]>
Co-authored-by: tavplubix <[email protected]>
Co-authored-by: Matwey V. Kornilov <[email protected]>
alexey-milovidov added a commit that referenced this pull request Jul 7, 2020
* fix arcadia build

* Fix JDBC @@session.variables

* Remove already fixed bug

* Slightly modernize code around ZooKeeper

* Fix @@session.variables AS

* try to rename py files to less common names

* add __init__.py

* update SELECT description (#11907)

Signed-off-by: Slach <[email protected]>

* [docs] extra F.A.Q. content (#11898)

* more content for F.A.Q.

* more content

* normalize

* more content

* maybe fix the docs check

* absolute img urls

* fix tests

* Keep alias after substitution of query parameters #11914

* show build commands

* Added a test

* Add SELECT @@Version fake value '5.7.30' #11089

* fix + bump tests

* Fix unitialized memory

* Fix using current database while checking access rights.

* fix style check - clang format for lambdas

* Better github-hook

* Do not update PVS Studio docker automatically.

They keep removing the old image every couple of weeks, and the entire
docker update fails.

* bump CI

* for the love of God just update this container already, i'm begging you

* Update Dockerfile

* Update pvs-studio version

* Fix jemalloc under OSX (by registering it as default zone explicitly)

In case of OSX jemalloc register itself as a default zone allocator.

But when you link statically then zone_register() will not be called,
and even will be optimized out:

  $ nm clickhouse.patched  | grep -c zone_register
  0

Fix this, by manually calling it.

v2: extern C

* Rewrite arithmetic in aggregate functions optimisation (#11899)

* remove clang-format tag comments

* Put clickhouse-local data to /tmp by default

This fixes #9848
Also fixes #11926

* trigger ci

* fix some logical errors

* Update features.html

* Consider allocatedBytes() instead of bytes() in Storage{Buffer,Memory}.

* fix query parameter visitor

* fixpu

* Update 00945_bloom_filter_index.sql

* Less layers in docker file

* Less layers in docker file

* Update docker/test/performance-comparison/perf.py

* rename test back to test.py

* client exit with unrecognized arguments

format code

fix

* remove useless const

* save

* Update canonized values in 00753_system_columns_and_system_tables.

* add ssd to integration test

* one more test

* Fix one reason of test flakiness

* Fix race condition in extractAllGroups

* extract JOIN in own plan step

* fix mistake reported by @Slach

* remove useless logic

* fix crash

* Revive mmap IO

* More verbose CMake in build docker

* Avro UUID support

* remove a trick with expression continuation

* Respect direct_io/mmap settings while reading secondary indices

* Minor modification

* Added a comment #11949

* Added a test

* Add CANNOT_PARSE_UUID extern const

* Fix estimation of the number of marks for various thresholds

* better ExpressionAction::execute()

* performance comparison

* add page fault perf events

* better error messages

* Add CPU frequencies to system.asynchronous_metrics

* Update AsynchronousMetrics.cpp

* keep ArrayJoin optimisation

* Update path to performance tests build

* tests with distributed

* place left join keys in before_join actions

* Added tests for #8692

* review fixes

* fix totals

* Update path to perf test package

* use std::filesystem::path

* Minor cleanup in Client.cpp before fuzzing

* Extend word break config to all non-alphanumeric chars

* Update AsynchronousMetrics.h

* more cleanup

* add test

update test

fix

* remove unused imports + bump tests

* Update 01345_array_join_LittleMaverick.sql

* Update ExpressionActions.h

* Fixes

* Add comment

* Remove empty lines

* Update system.md (#11945)

* Update system.md

Translate the doc to Chinese

* Update system.md

* fix the title's translattion error (#11939)

@zhang2014 I use MergeTree replaced  Chinese version "合并“, and fix an error.

* Add __init__.py

* Remove strange header

* Trying to fix ya.make

* Update replxx submodule

* Add a test for #10102

* disable tests in arcadia

* Added a test from #5131

* Try to enable long perf tests

* performance comparison

* longer

* Support Enums type for MySQL engine #3985

* performance comparison

* Add integration test for MySQL enums type

* Fix bad log message at server startup

* Insert enum column values for test

* Better diagnostics of "Replica {} appears to be already active" message

* Fix typos

* Added a test for #8550

* Update extended-roadmap.md

* Update test

* Fix FPE, step 1

* Make it more correct

* Add a test

* Avoid floating point error in geohashesInBox #11369

* Avro: allow missing fields

* update

* Fix build

* Revert "[experiment] maybe fix warnings in integration tests"

* Add xeus-clickhouse (#12010)

xeus-clickhouse is a Jupyter kernal for ClickHouse

* Fix test

* Fix array size overflow in generateRandom

* Added a test

* Update ErrorCodes.cpp

* More hardening

* More hardening

* Fix access rights: cannot grant DDL when allow_ddl=0

* Add tests

* Add test test_allow_ddl.

* Added failing test

* Remove the usage of obsolete setting

* Whitespace

* Added a test

* Allow to ALTER partition key in some cases

* Slightly more safe

* Only allow Enum extension within the same width

* Update test

* Added failing test for Replicated table

* Fix clang-tidy

* Whitespace

* Write partition key changes to ZooKeeper

* Typos

* Implement for ReplicatedMergeTree

* Added test reference

* Added missing ORDER BY in test

* Fix integration test

* Fix error in addMonths with floating point argument

* Fix error in addMonths with floating point argument

* Fix overflow in function "neighbor"

* Whitespace

* Whitespace

* clickhouse-local: logging flags fixes

* clickhouse-local: use std::filesystem::equivalent

* Limit /proc/cpuinfo metrics to linux only

* Feature 8074 (#12014)

* refs #8074 1: start to stream

* refs final check format and spell

* refs final check format and spell

* refs #8074 fix up link to sql-reference/functions/other-functions

* Bump idna from 2.9 to 2.10 in /docs/tools

Bumps [idna](https://github.com/kjd/idna) from 2.9 to 2.10.
- [Release notes](https://github.com/kjd/idna/releases)
- [Changelog](https://github.com/kjd/idna/blob/master/HISTORY.rst)
- [Commits](kjd/idna@v2.9...v2.10)

Signed-off-by: dependabot-preview[bot] <[email protected]>

* make a short test for DateTime

* DOCS-636 Synchronized some edits from EN to RU (#11941)

* [review][clickhousedocs][translate] DOCSUP-1351: Edit and translate to Russian (#129)

* DOCSUP-1351: Add blockSerializedSize (RU)

* DOCSUP-1351: Fix blockSerializedSize description by function description template.

* DOCSUP-1351: PR8756- Update Distributed engine section.

* DOCSUP-1351: PR9076-Show Queries more like MySQL did.

* DOCSUP-1351: PR#9919-system.tables improvements (total_rows/total_bytes/storage_policy)

* DOCSUP-1351: (ru) blockSerializedSize remake by template.

* DOCSUP-1351: PR#9598-Add function arrayReduceInRange and update arrayReduce function.

* DOCSUP-1351: PR#9598 Fix arrayReduce and arrayReduceInRanges sections by template.

* DOCSUP-1351: Some fixes.

* DOCSUP-1351: Some fixes.

Co-authored-by: romanzhukov <[email protected]>

* CLICKHOUSEDOCS-636: Minor changes.

Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Roman Bug <[email protected]>
Co-authored-by: romanzhukov <[email protected]>

* Temporary enable debug logs when releasing docs

* Better docker images list

* [docs] improve stable releases discovery

* Automated backporting machinery (#12029)

* Add automated cherry-pick machinery

* Added script for backporting machinery

* Implement dry-run mode

* Comment old methods

* Fix python2

* Add ya.make for sandbox tasks

* Remove old stuff

* Add TLB misses perf counters.

* Update ThreadProfileEvents.cpp

* Fake change in dockerfile

* Fix tuple nullable comparison.

* fixup

* Update ThreadProfileEvents.cpp

* Fix test.

* Added test.

* Fix test.

* Update ITransformingStep.h

* Make topK return Enum for Enum types

* Update ThreadProfileEvents.cpp

* Update browse-code.md (#12047)

* Update browse-code.md

纠正了一些翻译错误。

* Update browse-code.md

Co-authored-by: Ivan Blinkov <[email protected]>

* Bump python-slugify from 1.2.6 to 4.0.1 in /docs/tools

Bumps [python-slugify](https://github.com/un33k/python-slugify) from 1.2.6 to 4.0.1.
- [Release notes](https://github.com/un33k/python-slugify/releases)
- [Changelog](https://github.com/un33k/python-slugify/blob/master/CHANGELOG.md)
- [Commits](un33k/python-slugify@1.2.6...4.0.1)

Signed-off-by: dependabot-preview[bot] <[email protected]>

* Update ThreadProfileEvents.cpp

* Update README.md

* Fix typo (#12046)

* fix low card types in merge join (#12035)

* Update contrib/poco to ClickHouse-Extras/poco #22 (#12037)

* Updated ClickHouse-Extras/poco #22

Co-authored-by: alexey-milovidov <[email protected]>
Co-authored-by: Anton Popov <[email protected]>
Co-authored-by: BohuTANG <[email protected]>
Co-authored-by: Nikolai Kochetov <[email protected]>
Co-authored-by: Ivan Blinkov <[email protected]>
Co-authored-by: Eugene Klimov <[email protected]>
Co-authored-by: Alexander Kuzmenkov <[email protected]>
Co-authored-by: Alexander Kuzmenkov <[email protected]>
Co-authored-by: Nikita Mikhaylov <[email protected]>
Co-authored-by: alesapin <[email protected]>
Co-authored-by: Vitaly Baranov <[email protected]>
Co-authored-by: Bharat Nallan <[email protected]>
Co-authored-by: Azat Khuzhin <[email protected]>
Co-authored-by: Artem Zuikov <[email protected]>
Co-authored-by: Alexander Tokmakov <[email protected]>
Co-authored-by: Maxim Akhmedov <[email protected]>
Co-authored-by: feng lv <[email protected]>
Co-authored-by: Nikita Mikhailov <[email protected]>
Co-authored-by: Andrew Onyshchuk <[email protected]>
Co-authored-by: Tom Bombadil <[email protected]>
Co-authored-by: Yuntao Wu <[email protected]>
Co-authored-by: Wang Fenjin <[email protected]>
Co-authored-by: Mikhail Gaidamaka <[email protected]>
Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
Co-authored-by: Nikolai Kochetov <[email protected]>
Co-authored-by: BayoNet <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Roman Bug <[email protected]>
Co-authored-by: romanzhukov <[email protected]>
Co-authored-by: Ivan <[email protected]>
Co-authored-by: chengy8934 <[email protected]>
Co-authored-by: MicrochipQ <[email protected]>
Co-authored-by: Alexander Kazakov <[email protected]>
alexey-milovidov added a commit that referenced this pull request Jul 7, 2020
…step 1. (#12231)

* Add tests

* Add test test_allow_ddl.

* Added failing test

* Remove the usage of obsolete setting

* Whitespace

* Added a test

* Allow to ALTER partition key in some cases

* Slightly more safe

* Only allow Enum extension within the same width

* Update test

* Added failing test for Replicated table

* Fix clang-tidy

* Whitespace

* Write partition key changes to ZooKeeper

* Typos

* Implement for ReplicatedMergeTree

* Added test reference

* Added missing ORDER BY in test

* Fix integration test

* Fix error in addMonths with floating point argument

* Fix error in addMonths with floating point argument

* Fix overflow in function "neighbor"

* Whitespace

* Whitespace

* Fix ORDER BY tuple with COLLATE on const column

* clickhouse-local: logging flags fixes

* clickhouse-local: use std::filesystem::equivalent

* Limit /proc/cpuinfo metrics to linux only

* Feature 8074 (#12014)

* refs #8074 1: start to stream

* refs final check format and spell

* refs final check format and spell

* refs #8074 fix up link to sql-reference/functions/other-functions

* Bump idna from 2.9 to 2.10 in /docs/tools

Bumps [idna](https://github.com/kjd/idna) from 2.9 to 2.10.
- [Release notes](https://github.com/kjd/idna/releases)
- [Changelog](https://github.com/kjd/idna/blob/master/HISTORY.rst)
- [Commits](kjd/idna@v2.9...v2.10)

Signed-off-by: dependabot-preview[bot] <[email protected]>

* make a short test for DateTime

* Fixup

* DOCS-636 Synchronized some edits from EN to RU (#11941)

* [review][clickhousedocs][translate] DOCSUP-1351: Edit and translate to Russian (#129)

* DOCSUP-1351: Add blockSerializedSize (RU)

* DOCSUP-1351: Fix blockSerializedSize description by function description template.

* DOCSUP-1351: PR8756- Update Distributed engine section.

* DOCSUP-1351: PR9076-Show Queries more like MySQL did.

* DOCSUP-1351: PR#9919-system.tables improvements (total_rows/total_bytes/storage_policy)

* DOCSUP-1351: (ru) blockSerializedSize remake by template.

* DOCSUP-1351: PR#9598-Add function arrayReduceInRange and update arrayReduce function.

* DOCSUP-1351: PR#9598 Fix arrayReduce and arrayReduceInRanges sections by template.

* DOCSUP-1351: Some fixes.

* DOCSUP-1351: Some fixes.

Co-authored-by: romanzhukov <[email protected]>

* CLICKHOUSEDOCS-636: Minor changes.

Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Roman Bug <[email protected]>
Co-authored-by: romanzhukov <[email protected]>

* Use ConcurentBoundedQueue instead of vector

* Temporary enable debug logs when releasing docs

* Better docker images list

* [docs] improve stable releases discovery

* Update contrib/jemalloc-cmake/CMakeLists.txt

* Remove libevent library

* Automated backporting machinery (#12029)

* Add automated cherry-pick machinery

* Added script for backporting machinery

* Implement dry-run mode

* Comment old methods

* Fix python2

* Add ya.make for sandbox tasks

* Remove old stuff

* Move writing to RabbitMQ into background task

* Add TLB misses perf counters.

* Update ThreadProfileEvents.cpp

* Fake change in dockerfile

* Fix tuple nullable comparison.

* Fix access rights: cannot grant INTROSPECTION when allow_introspection_functions=0.

* fixup

* Update ThreadProfileEvents.cpp

* Fix test.

* Added test.

* Fix and simplify code

* Fix test.

* Update ITransformingStep.h

* Fix "Sharding key is not deterministic" message

* Do not check *optimize_skip_unused_shards_nesting w/o *optimize_skip_unused_shards

This will avoid supperior log message in case of
*optimize_skip_unused_shards_nesting already disables it.
And also it is logical.

* Remove test that is not supported by "Arcadia" build system

* Fix constraints check for constant columns

* Make topK return Enum for Enum types

* parse metadata in parallel when loading tables

* Fix error

* Fix build

* fixup

* Update ThreadProfileEvents.cpp

* Update browse-code.md (#12047)

* Update browse-code.md

纠正了一些翻译错误。

* Update browse-code.md

Co-authored-by: Ivan Blinkov <[email protected]>

* Bump python-slugify from 1.2.6 to 4.0.1 in /docs/tools

Bumps [python-slugify](https://github.com/un33k/python-slugify) from 1.2.6 to 4.0.1.
- [Release notes](https://github.com/un33k/python-slugify/releases)
- [Changelog](https://github.com/un33k/python-slugify/blob/master/CHANGELOG.md)
- [Commits](un33k/python-slugify@1.2.6...4.0.1)

Signed-off-by: dependabot-preview[bot] <[email protected]>

* Update ThreadProfileEvents.cpp

* Update README.md

* Fix typo (#12046)

* Fix test_allow_introspection.

* Try fix labda tuple(LC) argument.

* Test image changes

* Try fix labda tuple(LC) argument.

* Add pvs studio to images

* Added test.

* fix low card types in merge join (#12035)

* Update contrib/poco to ClickHouse-Extras/poco #22 (#12037)

* Updated ClickHouse-Extras/poco #22

* Fix defaultValueOfArgumentType

* Added test.

* Update cpu_synthetic.xml

* Moves task shall be started if new storage policy needs them.

* Added test for automatic start of background move task.

* Add ability to run any image version from packager and runner

* Check type of filter for prewhere.

* Check type of filter for prewhere.

* Check type of filter for prewhere.

* Check type of filter for prewhere.

* Added test.

* Try fix pk in tuple performance

Possible approach for fixing #10574

The problem is that prepared sets are built correctly, it is a hash map of key -> set
where key is a hash of AST and list of data types (when we a list of
tuples of literals).

However, when the key is built from the index to try and find if there
exists a prepared set that would match it looks for data types of the
primary key (see how data_types is populated) because the primary key
has only one field (v in my example) it can not find the prepared set.

The patch looks for any prepared indexes where data types match for the
subset of fields found in primary key, we are not interested in other
fields anyway for the purpose of primary key pruning.

* Fix partial revokes (complex cases).

* Changelog for 20.3.11, 12

* simple changelog script

* bump CI

* Fix tests.

* Add explicit test for a case where AST hashes collide for different prepared sets

* [blog] add RSS feed (#12064)

* [blog] add rss feed

* better title

* Update CHANGELOG.md

Co-authored-by: Ivan Blinkov <[email protected]>

* bump ci

* Moved useless S3 logging to TRACE level.

* Add a test to cover non-const tuple elemenets (just in case)

* Bump

* Update query-complexity.md

Remove a note about read limits applied on threads level.

* Update query-complexity.md

* Update query-complexity.md

* Update query-complexity.md

* DOCS-609: max_server_memory_usage (#11771)

* Revolg DOCSUP-1000 add max server memory usage setting (#125)

* Add max_server_memory_usage setting, delete max_memory_usage_for_all_queries setting.

* Syntax fixed

* Apply suggestions from code review

Co-authored-by: BayoNet <[email protected]>

* Doc for the max_server_memory_usage setting. Updates.

Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-609: Minor fixes.

* CLICKHOUSEDOCS-609: Actualized position of the setting.

Co-authored-by: olgarev <[email protected]>
Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>

* Add force_primary_key to a pk in tuple test

* DOCS-510: runningAccumulate (#12061)

* asiana21-DOCSUP-797 (#117)

* docs(runningAccumulate): the function description is added

* docs(runningAccumulate): the function description is modified

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* docs(runningAccumulate): some changes

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* docs(runningAccumulate): added ru translation

Co-authored-by: asiana21 <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-510: Minor fix.

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: Ivan Blinkov <[email protected]>

* CLICKHOUSEDOCS-510: Fixed links.

Co-authored-by: AsiaKorushkina <[email protected]>
Co-authored-by: asiana21 <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Ivan Blinkov <[email protected]>

* Remove const specifier to allow auto-move (clangtidy)

* Rewrite Set lookup to make it more readable

* [docs] Sync zh/development/build-osx.md from EN (#12071)

* ISSUES-4006 support first for ALTER ADD|MODIFY COLUMN

* Update deb image

* Don't download image twice

* Remove garbage from images

* bump ci

* fixup

* DOCS-635: Translated the EN version of the AvroConfluent format description (#11930)

* DOCSUP-1350 (#128)

* edited EN version

* add EN and RU translation

* minor changes

* CLICKHOUSEDOCS-635: Updated the description.

Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Evgenia Sudarikova <[email protected]>

* Fix tests.

* Better PVS image

* DOCS-605: Description for the always_fetch_merged_part setting (#11921)

* Revolg DOCSUP-998 Document the always_fetch_merged_part setting (#123)

* Add always_fetch_merged_part setting

* revolg-DOCSUP-998-add_always_fetch_merged_part_setting link fixed

* Apply suggestions from code review

Co-authored-by: BayoNet <[email protected]>

* Add always_fetch_merged_part setting. Updates.

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* Add always_fetch_merged_part setting. Updates.

Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-605: Minor fixes.

* CLICKHOUSEDOCS-605: Added Plausible to Adopters.

* Update docs/ru/operations/settings/settings.md

Co-authored-by: alesapin <[email protected]>

* Update docs/en/operations/settings/settings.md

Co-authored-by: alesapin <[email protected]>

* CLICKHOUSEDOCS-605: Fixed access rights description.

Co-authored-by: olgarev <[email protected]>
Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: alesapin <[email protected]>

* Update Dockerfile

* revert e9d3c48

* [blog] 'Package Repository Behind CDN' post (#12082)

* support iframes from DataLens

* initial blog post text

* Improve REVOKE command: now it requires only grant/admin option for only
access which will be revoked.
REVOKE ALL FROM user1 now revokes all granted roles.

* Fix limiting the number of threads for VIEW.

* Update tips.md

* Added test.

* Remove pvs studio from images list

* Better shutdown and conversion

* Reverse arguments

* Fix result_rows and result_bytes metrics for selects.

* Fix result_rows and result_bytes metrics for selects.

* improve breadcrumbs markup

* Fix tests.

* Less race conditions

* [docker] install ca-certificates before the first apt-get update (#12095)

* [docker] install ca-certificates before first apt-get update

* Update Dockerfile

* DOCS-522: max_parser_depth (#12097)

* asiana21-DOCSUP-925-max_parser_depth (#132)

* docs(max_parser_depth): added the setting description

* docs(max_parser_depth): some changes

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* docs(max_parser_depth): added ru translation

* docs(max_parser_depth): removed quotation marks

Co-authored-by: asiana21 <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-522: Fixed the link.

Co-authored-by: AsiaKorushkina <[email protected]>
Co-authored-by: asiana21 <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>

* Added results for AWS Lightsail

* (typo) in doc (#12099)

* Added test.

* Create codeql-analysis.yml

* Tiny fixes

* Create anchore-analysis.yml

* Update README.md

* Fix test (#12088)

* Test for a fixed issue #10668, related to input_format_allow_errors_num in CSV

* Add unbundled mode flag

* Remove LC converting to Arrow.

* Remove LC converting to Arrow.

* Move skip lists to clickhouse-test

* Remove LC converting to Arrow.

* More verbose message about skip

* Make skip-list optional

* Added test.

* Add type column in system.disks

* Update clickhouse-test

* Update 01355_CSV_input_format_allow_errors.sh

* Added a showcase of minimal Docker image

* Added a comment

* Added a comment

* Added a comment

* Formatting

* contrib/unixodbc-cmake: Fix build when UNBUNDLED

target_compile_definitions may only set INTERFACE properties on IMPORTED targets

* Fix version column in replicated version collapsing merge tree (#12121)

* poco-cmake: Fix Poco::Data::ODBC target when UNBUNDLED

By default IMPORTED target has a scope in the directory in which it is created
and below. This leads to the following issues when building UNBUNDLED:

Target "clickhouse" links to target "Poco::Data::ODBC" but the target was not
found.  Perhaps a find_package() call is missing for an IMPORTED target, or an
ALIAS target is missing?

* Add missed <atomic> include in ProxyListConfiguration

* Improve performace of reading in order of sorting key. (#11696)

* simplify reading in order of sorting key

* add perf test for reading many parts

* Revert "simplify reading in order of sorting key"

This reverts commit 7267d7c.

* add threshold for preliminary merge for reading in order

* better threshold

* limit threads in test

* Normalize "pid" file handling #3501

* Update StatusFile.cpp

* Added a test

* Remove harmful code from "geoDistance" #12117

* Fix warnings from CodeQL

* Added a test

* Minor modification

* Update libdivide to the latest master

* Replace exit to abort in libdivide

* Fix potential overflow in integer division #12119

* Added a test

* Whitespace

* Added a test for #4211

* Attempt to fix "Arcadia" build

* Rename test

* Update arraySum.cpp

* ILIKE operator (#12125)

* Integrated CachingAllocator into MarkCache

* fixed build errors

* reset func hotfix

* upd: Fixing build

* updated submodules links

* fix 2

* updating grabber allocator proto

* updating lost work

* updating CMake to use concepts

* some other changes to get it building (integration into MarkCache)

* further integration into caches

* updated Async metrics, fixed some build errors

* and some other errors revealing

* added perfect forwarding to some functions

* fix: forward template

* fix: constexpr modifier

* fix: FakePODAllocator missing member func

* updated PODArray constructor taking alloc params

* fix: PODArray overload with n restored

* fix: FakePODAlloc duplicating alloc() func

* added constexpr variable for alloc_tag_t

* split cache values by allocators, provided updates

* fix: memcpy

* fix: constexpr modifier

* fix: noexcept modifier

* fix: alloc_tag_t for PODArray constructor

* fix: PODArray copy ctor with different alloc

* fix: resize() signature

* updating to lastest working master

* syncing with 273267

* first draft version

* fix: update Searcher to case-insensitive

* added ILIKE test

* fixed style errors, updated test, split like and ilike,  added notILike

* replaced inconsistent comments

* fixed show tables ilike

* updated missing test cases

* regenerated ya.make

* Update 01355_ilike.sql

Co-authored-by: myrrc <[email protected]>
Co-authored-by: alexey-milovidov <[email protected]>

Co-authored-by: Andrew Onyshchuk <[email protected]>
Co-authored-by: Vitaly Baranov <[email protected]>
Co-authored-by: alexey-milovidov <[email protected]>
Co-authored-by: Mikhail Gaidamaka <[email protected]>
Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
Co-authored-by: Alexander Kuzmenkov <[email protected]>
Co-authored-by: Nikolai Kochetov <[email protected]>
Co-authored-by: Ivan Blinkov <[email protected]>
Co-authored-by: alesapin <[email protected]>
Co-authored-by: BayoNet <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Roman Bug <[email protected]>
Co-authored-by: romanzhukov <[email protected]>
Co-authored-by: kssenii <[email protected]>
Co-authored-by: tavplubix <[email protected]>
Co-authored-by: Alexander Kuzmenkov <[email protected]>
Co-authored-by: Ivan <[email protected]>
Co-authored-by: Nikita Mikhaylov <[email protected]>
Co-authored-by: Azat Khuzhin <[email protected]>
Co-authored-by: chengy8934 <[email protected]>
Co-authored-by: MicrochipQ <[email protected]>
Co-authored-by: Artem Zuikov <[email protected]>
Co-authored-by: Alexander Kazakov <[email protected]>
Co-authored-by: Vladimir Chebotarev <[email protected]>
Co-authored-by: Nicolae Vartolomei <[email protected]>
Co-authored-by: filimonov <[email protected]>
Co-authored-by: olgarev <[email protected]>
Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: AsiaKorushkina <[email protected]>
Co-authored-by: asiana21 <[email protected]>
Co-authored-by: BohuTANG <[email protected]>
Co-authored-by: zhang2014 <[email protected]>
Co-authored-by: Evgenia Sudarikova <[email protected]>
Co-authored-by: Anton Popov <[email protected]>
Co-authored-by: manmitya <[email protected]>
Co-authored-by: Nikolai Kochetov <[email protected]>
Co-authored-by: Mikhail Filimonov <[email protected]>
Co-authored-by: Anton Ivashkin <[email protected]>
Co-authored-by: Ilya Yatsishin <[email protected]>
Co-authored-by: tavplubix <[email protected]>
Co-authored-by: Matwey V. Kornilov <[email protected]>
Co-authored-by: myrrc <[email protected]>
Co-authored-by: myrrc <[email protected]>
alexey-milovidov added a commit that referenced this pull request Jul 7, 2020
…umn (#12272)

* fix arcadia build

* Fix JDBC @@session.variables

* Remove already fixed bug

* Slightly modernize code around ZooKeeper

* Fix @@session.variables AS

* try to rename py files to less common names

* add __init__.py

* update SELECT description (#11907)

Signed-off-by: Slach <[email protected]>

* [docs] extra F.A.Q. content (#11898)

* more content for F.A.Q.

* more content

* normalize

* more content

* maybe fix the docs check

* absolute img urls

* fix tests

* Keep alias after substitution of query parameters #11914

* show build commands

* Added a test

* Add SELECT @@Version fake value '5.7.30' #11089

* fix + bump tests

* Fix unitialized memory

* Fix using current database while checking access rights.

* fix style check - clang format for lambdas

* Better github-hook

* Do not update PVS Studio docker automatically.

They keep removing the old image every couple of weeks, and the entire
docker update fails.

* bump CI

* for the love of God just update this container already, i'm begging you

* Update Dockerfile

* Update pvs-studio version

* Fix jemalloc under OSX (by registering it as default zone explicitly)

In case of OSX jemalloc register itself as a default zone allocator.

But when you link statically then zone_register() will not be called,
and even will be optimized out:

  $ nm clickhouse.patched  | grep -c zone_register
  0

Fix this, by manually calling it.

v2: extern C

* Rewrite arithmetic in aggregate functions optimisation (#11899)

* remove clang-format tag comments

* Put clickhouse-local data to /tmp by default

This fixes #9848
Also fixes #11926

* trigger ci

* fix some logical errors

* Update features.html

* Consider allocatedBytes() instead of bytes() in Storage{Buffer,Memory}.

* fix query parameter visitor

* fixpu

* Update 00945_bloom_filter_index.sql

* Less layers in docker file

* Less layers in docker file

* Update docker/test/performance-comparison/perf.py

* rename test back to test.py

* client exit with unrecognized arguments

format code

fix

* remove useless const

* save

* Update canonized values in 00753_system_columns_and_system_tables.

* add ssd to integration test

* one more test

* Fix one reason of test flakiness

* Fix race condition in extractAllGroups

* extract JOIN in own plan step

* fix mistake reported by @Slach

* remove useless logic

* fix crash

* Revive mmap IO

* More verbose CMake in build docker

* Avro UUID support

* remove a trick with expression continuation

* Respect direct_io/mmap settings while reading secondary indices

* Minor modification

* Added a comment #11949

* Added a test

* Add CANNOT_PARSE_UUID extern const

* Fix estimation of the number of marks for various thresholds

* better ExpressionAction::execute()

* performance comparison

* add page fault perf events

* better error messages

* Add CPU frequencies to system.asynchronous_metrics

* Update AsynchronousMetrics.cpp

* keep ArrayJoin optimisation

* Update path to performance tests build

* tests with distributed

* place left join keys in before_join actions

* Added tests for #8692

* review fixes

* fix totals

* Update path to perf test package

* use std::filesystem::path

* Minor cleanup in Client.cpp before fuzzing

* Extend word break config to all non-alphanumeric chars

* Update AsynchronousMetrics.h

* more cleanup

* add test

update test

fix

* remove unused imports + bump tests

* Update 01345_array_join_LittleMaverick.sql

* Update ExpressionActions.h

* Fixes

* Add comment

* Remove empty lines

* Update system.md (#11945)

* Update system.md

Translate the doc to Chinese

* Update system.md

* fix the title's translattion error (#11939)

@zhang2014 I use MergeTree replaced  Chinese version "合并“, and fix an error.

* Add __init__.py

* Remove strange header

* Trying to fix ya.make

* Update replxx submodule

* Add a test for #10102

* disable tests in arcadia

* Added a test from #5131

* Try to enable long perf tests

* performance comparison

* longer

* Support Enums type for MySQL engine #3985

* performance comparison

* Add integration test for MySQL enums type

* Fix bad log message at server startup

* Insert enum column values for test

* Better diagnostics of "Replica {} appears to be already active" message

* Fix typos

* Added a test for #8550

* Update extended-roadmap.md

* Update test

* Fix FPE, step 1

* Make it more correct

* Add a test

* Avoid floating point error in geohashesInBox #11369

* Avro: allow missing fields

* update

* Fix build

* Revert "[experiment] maybe fix warnings in integration tests"

* Add xeus-clickhouse (#12010)

xeus-clickhouse is a Jupyter kernal for ClickHouse

* Fix test

* Fix array size overflow in generateRandom

* Added a test

* Update ErrorCodes.cpp

* More hardening

* More hardening

* Fix access rights: cannot grant DDL when allow_ddl=0

* Add tests

* Add test test_allow_ddl.

* Added failing test

* Remove the usage of obsolete setting

* Whitespace

* Added a test

* Allow to ALTER partition key in some cases

* Slightly more safe

* Only allow Enum extension within the same width

* Update test

* Added failing test for Replicated table

* Fix clang-tidy

* Whitespace

* Write partition key changes to ZooKeeper

* Typos

* Implement for ReplicatedMergeTree

* Added test reference

* Added missing ORDER BY in test

* Fix integration test

* Fix error in addMonths with floating point argument

* Fix error in addMonths with floating point argument

* Fix overflow in function "neighbor"

* Whitespace

* Whitespace

* clickhouse-local: logging flags fixes

* clickhouse-local: use std::filesystem::equivalent

* Limit /proc/cpuinfo metrics to linux only

* Feature 8074 (#12014)

* refs #8074 1: start to stream

* refs final check format and spell

* refs final check format and spell

* refs #8074 fix up link to sql-reference/functions/other-functions

* Bump idna from 2.9 to 2.10 in /docs/tools

Bumps [idna](https://github.com/kjd/idna) from 2.9 to 2.10.
- [Release notes](https://github.com/kjd/idna/releases)
- [Changelog](https://github.com/kjd/idna/blob/master/HISTORY.rst)
- [Commits](kjd/idna@v2.9...v2.10)

Signed-off-by: dependabot-preview[bot] <[email protected]>

* make a short test for DateTime

* DOCS-636 Synchronized some edits from EN to RU (#11941)

* [review][clickhousedocs][translate] DOCSUP-1351: Edit and translate to Russian (#129)

* DOCSUP-1351: Add blockSerializedSize (RU)

* DOCSUP-1351: Fix blockSerializedSize description by function description template.

* DOCSUP-1351: PR8756- Update Distributed engine section.

* DOCSUP-1351: PR9076-Show Queries more like MySQL did.

* DOCSUP-1351: PR#9919-system.tables improvements (total_rows/total_bytes/storage_policy)

* DOCSUP-1351: (ru) blockSerializedSize remake by template.

* DOCSUP-1351: PR#9598-Add function arrayReduceInRange and update arrayReduce function.

* DOCSUP-1351: PR#9598 Fix arrayReduce and arrayReduceInRanges sections by template.

* DOCSUP-1351: Some fixes.

* DOCSUP-1351: Some fixes.

Co-authored-by: romanzhukov <[email protected]>

* CLICKHOUSEDOCS-636: Minor changes.

Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Roman Bug <[email protected]>
Co-authored-by: romanzhukov <[email protected]>

* Temporary enable debug logs when releasing docs

* Better docker images list

* [docs] improve stable releases discovery

* Automated backporting machinery (#12029)

* Add automated cherry-pick machinery

* Added script for backporting machinery

* Implement dry-run mode

* Comment old methods

* Fix python2

* Add ya.make for sandbox tasks

* Remove old stuff

* Add TLB misses perf counters.

* Update ThreadProfileEvents.cpp

* Fake change in dockerfile

* Fix tuple nullable comparison.

* fixup

* Update ThreadProfileEvents.cpp

* Fix test.

* Added test.

* Fix test.

* Update ITransformingStep.h

* Make topK return Enum for Enum types

* Update ThreadProfileEvents.cpp

* Update browse-code.md (#12047)

* Update browse-code.md

纠正了一些翻译错误。

* Update browse-code.md

Co-authored-by: Ivan Blinkov <[email protected]>

* Bump python-slugify from 1.2.6 to 4.0.1 in /docs/tools

Bumps [python-slugify](https://github.com/un33k/python-slugify) from 1.2.6 to 4.0.1.
- [Release notes](https://github.com/un33k/python-slugify/releases)
- [Changelog](https://github.com/un33k/python-slugify/blob/master/CHANGELOG.md)
- [Commits](un33k/python-slugify@1.2.6...4.0.1)

Signed-off-by: dependabot-preview[bot] <[email protected]>

* Update ThreadProfileEvents.cpp

* Update README.md

* Fix typo (#12046)

* fix low card types in merge join (#12035)

* Update contrib/poco to ClickHouse-Extras/poco #22 (#12037)

* Updated ClickHouse-Extras/poco #22

* Cherry pick #12020 to 20.5: Fix ORDER BY tuple with COLLATE on const column (#12203)

* Fix ORDER BY tuple with COLLATE on const column

* Remove test that is not supported by "Arcadia" build system

Co-authored-by: Alexey Milovidov <[email protected]>

Co-authored-by: alexey-milovidov <[email protected]>
Co-authored-by: Anton Popov <[email protected]>
Co-authored-by: BohuTANG <[email protected]>
Co-authored-by: Nikolai Kochetov <[email protected]>
Co-authored-by: Ivan Blinkov <[email protected]>
Co-authored-by: Eugene Klimov <[email protected]>
Co-authored-by: Alexander Kuzmenkov <[email protected]>
Co-authored-by: Alexander Kuzmenkov <[email protected]>
Co-authored-by: Nikita Mikhaylov <[email protected]>
Co-authored-by: alesapin <[email protected]>
Co-authored-by: Vitaly Baranov <[email protected]>
Co-authored-by: Bharat Nallan <[email protected]>
Co-authored-by: Azat Khuzhin <[email protected]>
Co-authored-by: Artem Zuikov <[email protected]>
Co-authored-by: Alexander Tokmakov <[email protected]>
Co-authored-by: Maxim Akhmedov <[email protected]>
Co-authored-by: feng lv <[email protected]>
Co-authored-by: Nikita Mikhailov <[email protected]>
Co-authored-by: Andrew Onyshchuk <[email protected]>
Co-authored-by: Tom Bombadil <[email protected]>
Co-authored-by: Yuntao Wu <[email protected]>
Co-authored-by: Wang Fenjin <[email protected]>
Co-authored-by: Mikhail Gaidamaka <[email protected]>
Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
Co-authored-by: Nikolai Kochetov <[email protected]>
Co-authored-by: BayoNet <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Roman Bug <[email protected]>
Co-authored-by: romanzhukov <[email protected]>
Co-authored-by: Ivan <[email protected]>
Co-authored-by: chengy8934 <[email protected]>
Co-authored-by: MicrochipQ <[email protected]>
Co-authored-by: Alexander Kazakov <[email protected]>
alesapin added a commit that referenced this pull request Jul 10, 2020
…first apt-get update (#12254)

* Minor modification

* Added a comment #11949

* Added a test

* Add CANNOT_PARSE_UUID extern const

* Fix estimation of the number of marks for various thresholds

* better ExpressionAction::execute()

* performance comparison

* add page fault perf events

* better error messages

* Add CPU frequencies to system.asynchronous_metrics

* Update AsynchronousMetrics.cpp

* keep ArrayJoin optimisation

* Update path to performance tests build

* tests with distributed

* place left join keys in before_join actions

* Added tests for #8692

* review fixes

* fix totals

* Update path to perf test package

* use std::filesystem::path

* Minor cleanup in Client.cpp before fuzzing

* Extend word break config to all non-alphanumeric chars

* Update AsynchronousMetrics.h

* more cleanup

* add test

update test

fix

* remove unused imports + bump tests

* Update 01345_array_join_LittleMaverick.sql

* Update ExpressionActions.h

* Fixes

* Add comment

* Remove empty lines

* Update system.md (#11945)

* Update system.md

Translate the doc to Chinese

* Update system.md

* fix the title's translattion error (#11939)

@zhang2014 I use MergeTree replaced  Chinese version "合并“, and fix an error.

* Add __init__.py

* Remove strange header

* Trying to fix ya.make

* Update replxx submodule

* Add a test for #10102

* disable tests in arcadia

* Added a test from #5131

* Try to enable long perf tests

* perf test: report queries with new functions separately

* performance comparison

* longer

* muzzy decay 10 ms

* Support Enums type for MySQL engine #3985

* performance comparison

* Add integration test for MySQL enums type

* Fix bad log message at server startup

* Insert enum column values for test

* Better diagnostics of "Replica {} appears to be already active" message

* Fix typos

* Added a test for #8550

* Update extended-roadmap.md

* Update test

* Fix FPE, step 1

* Make it more correct

* Add a test

* Avoid floating point error in geohashesInBox #11369

* Avro: allow missing fields

* update

* Fix build

* Revert "[experiment] maybe fix warnings in integration tests"

* Add xeus-clickhouse (#12010)

xeus-clickhouse is a Jupyter kernal for ClickHouse

* Fix test

* Fix array size overflow in generateRandom

* Added a test

* Update ErrorCodes.cpp

* More hardening

* More hardening

* Fix access rights: cannot grant DDL when allow_ddl=0

* Add tests

* Add test test_allow_ddl.

* Added failing test

* Remove the usage of obsolete setting

* Whitespace

* Added a test

* Allow to ALTER partition key in some cases

* Slightly more safe

* Only allow Enum extension within the same width

* Update test

* Added failing test for Replicated table

* Fix clang-tidy

* Whitespace

* Write partition key changes to ZooKeeper

* Typos

* Implement for ReplicatedMergeTree

* Added test reference

* Added missing ORDER BY in test

* Fix integration test

* Fix error in addMonths with floating point argument

* Fix error in addMonths with floating point argument

* Fix overflow in function "neighbor"

* Whitespace

* Whitespace

* Fix ORDER BY tuple with COLLATE on const column

* clickhouse-local: logging flags fixes

* clickhouse-local: use std::filesystem::equivalent

* Limit /proc/cpuinfo metrics to linux only

* Feature 8074 (#12014)

* refs #8074 1: start to stream

* refs final check format and spell

* refs final check format and spell

* refs #8074 fix up link to sql-reference/functions/other-functions

* Bump idna from 2.9 to 2.10 in /docs/tools

Bumps [idna](https://github.com/kjd/idna) from 2.9 to 2.10.
- [Release notes](https://github.com/kjd/idna/releases)
- [Changelog](https://github.com/kjd/idna/blob/master/HISTORY.rst)
- [Commits](kjd/idna@v2.9...v2.10)

Signed-off-by: dependabot-preview[bot] <[email protected]>

* make a short test for DateTime

* Fixup

* DOCS-636 Synchronized some edits from EN to RU (#11941)

* [review][clickhousedocs][translate] DOCSUP-1351: Edit and translate to Russian (#129)

* DOCSUP-1351: Add blockSerializedSize (RU)

* DOCSUP-1351: Fix blockSerializedSize description by function description template.

* DOCSUP-1351: PR8756- Update Distributed engine section.

* DOCSUP-1351: PR9076-Show Queries more like MySQL did.

* DOCSUP-1351: PR#9919-system.tables improvements (total_rows/total_bytes/storage_policy)

* DOCSUP-1351: (ru) blockSerializedSize remake by template.

* DOCSUP-1351: PR#9598-Add function arrayReduceInRange and update arrayReduce function.

* DOCSUP-1351: PR#9598 Fix arrayReduce and arrayReduceInRanges sections by template.

* DOCSUP-1351: Some fixes.

* DOCSUP-1351: Some fixes.

Co-authored-by: romanzhukov <[email protected]>

* CLICKHOUSEDOCS-636: Minor changes.

Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Roman Bug <[email protected]>
Co-authored-by: romanzhukov <[email protected]>

* Temporary enable debug logs when releasing docs

* Better docker images list

* [docs] improve stable releases discovery

* Update contrib/jemalloc-cmake/CMakeLists.txt

* Automated backporting machinery (#12029)

* Add automated cherry-pick machinery

* Added script for backporting machinery

* Implement dry-run mode

* Comment old methods

* Fix python2

* Add ya.make for sandbox tasks

* Remove old stuff

* Add TLB misses perf counters.

* Update ThreadProfileEvents.cpp

* Fake change in dockerfile

* Fix tuple nullable comparison.

* Fix access rights: cannot grant INTROSPECTION when allow_introspection_functions=0.

* fixup

* Update ThreadProfileEvents.cpp

* Fix test.

* Added test.

* Fix test.

* Update ITransformingStep.h

* Fix "Sharding key is not deterministic" message

* Do not check *optimize_skip_unused_shards_nesting w/o *optimize_skip_unused_shards

This will avoid supperior log message in case of
*optimize_skip_unused_shards_nesting already disables it.
And also it is logical.

* Remove test that is not supported by "Arcadia" build system

* Make topK return Enum for Enum types

* parse metadata in parallel when loading tables

* fixup

* Update ThreadProfileEvents.cpp

* Update browse-code.md (#12047)

* Update browse-code.md

纠正了一些翻译错误。

* Update browse-code.md

Co-authored-by: Ivan Blinkov <[email protected]>

* Bump python-slugify from 1.2.6 to 4.0.1 in /docs/tools

Bumps [python-slugify](https://github.com/un33k/python-slugify) from 1.2.6 to 4.0.1.
- [Release notes](https://github.com/un33k/python-slugify/releases)
- [Changelog](https://github.com/un33k/python-slugify/blob/master/CHANGELOG.md)
- [Commits](un33k/python-slugify@1.2.6...4.0.1)

Signed-off-by: dependabot-preview[bot] <[email protected]>

* Update ThreadProfileEvents.cpp

* Update README.md

* Fix typo (#12046)

* Fix test_allow_introspection.

* Try fix labda tuple(LC) argument.

* Test image changes

* Try fix labda tuple(LC) argument.

* Add pvs studio to images

* Added test.

* fix low card types in merge join (#12035)

* Update contrib/poco to ClickHouse-Extras/poco #22 (#12037)

* Updated ClickHouse-Extras/poco #22

* Fix defaultValueOfArgumentType

* Added test.

* Update cpu_synthetic.xml

* Moves task shall be started if new storage policy needs them.

* Added test for automatic start of background move task.

* Add ability to run any image version from packager and runner

* Try fix pk in tuple performance

Possible approach for fixing #10574

The problem is that prepared sets are built correctly, it is a hash map of key -> set
where key is a hash of AST and list of data types (when we a list of
tuples of literals).

However, when the key is built from the index to try and find if there
exists a prepared set that would match it looks for data types of the
primary key (see how data_types is populated) because the primary key
has only one field (v in my example) it can not find the prepared set.

The patch looks for any prepared indexes where data types match for the
subset of fields found in primary key, we are not interested in other
fields anyway for the purpose of primary key pruning.

* Fix partial revokes (complex cases).

* Changelog for 20.3.11, 12

* simple changelog script

* bump CI

* Add explicit test for a case where AST hashes collide for different prepared sets

* [blog] add RSS feed (#12064)

* [blog] add rss feed

* better title

* Update CHANGELOG.md

Co-authored-by: Ivan Blinkov <[email protected]>

* bump ci

* Moved useless S3 logging to TRACE level.

* Add a test to cover non-const tuple elemenets (just in case)

* Bump

* DOCS-609: max_server_memory_usage (#11771)

* Revolg DOCSUP-1000 add max server memory usage setting (#125)

* Add max_server_memory_usage setting, delete max_memory_usage_for_all_queries setting.

* Syntax fixed

* Apply suggestions from code review

Co-authored-by: BayoNet <[email protected]>

* Doc for the max_server_memory_usage setting. Updates.

Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-609: Minor fixes.

* CLICKHOUSEDOCS-609: Actualized position of the setting.

Co-authored-by: olgarev <[email protected]>
Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>

* Add force_primary_key to a pk in tuple test

* DOCS-510: runningAccumulate (#12061)

* asiana21-DOCSUP-797 (#117)

* docs(runningAccumulate): the function description is added

* docs(runningAccumulate): the function description is modified

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* docs(runningAccumulate): some changes

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* docs(runningAccumulate): added ru translation

Co-authored-by: asiana21 <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-510: Minor fix.

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: Ivan Blinkov <[email protected]>

* CLICKHOUSEDOCS-510: Fixed links.

Co-authored-by: AsiaKorushkina <[email protected]>
Co-authored-by: asiana21 <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Ivan Blinkov <[email protected]>

* Remove const specifier to allow auto-move (clangtidy)

* Rewrite Set lookup to make it more readable

* [docs] Sync zh/development/build-osx.md from EN (#12071)

* Update deb image

* Don't download image twice

* Remove garbage from images

* bump ci

* fixup

* DOCS-635: Translated the EN version of the AvroConfluent format description (#11930)

* DOCSUP-1350 (#128)

* edited EN version

* add EN and RU translation

* minor changes

* CLICKHOUSEDOCS-635: Updated the description.

Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Evgenia Sudarikova <[email protected]>

* Better PVS image

* DOCS-605: Description for the always_fetch_merged_part setting (#11921)

* Revolg DOCSUP-998 Document the always_fetch_merged_part setting (#123)

* Add always_fetch_merged_part setting

* revolg-DOCSUP-998-add_always_fetch_merged_part_setting link fixed

* Apply suggestions from code review

Co-authored-by: BayoNet <[email protected]>

* Add always_fetch_merged_part setting. Updates.

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* Add always_fetch_merged_part setting. Updates.

Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-605: Minor fixes.

* CLICKHOUSEDOCS-605: Added Plausible to Adopters.

* Update docs/ru/operations/settings/settings.md

Co-authored-by: alesapin <[email protected]>

* Update docs/en/operations/settings/settings.md

Co-authored-by: alesapin <[email protected]>

* CLICKHOUSEDOCS-605: Fixed access rights description.

Co-authored-by: olgarev <[email protected]>
Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: alesapin <[email protected]>

* Update Dockerfile

* revert e9d3c48

* [blog] 'Package Repository Behind CDN' post (#12082)

* support iframes from DataLens

* initial blog post text

* Update tips.md

* Remove pvs studio from images list

* improve breadcrumbs markup

* [docker] install ca-certificates before the first apt-get update (#12095)

* [docker] install ca-certificates before first apt-get update

* Update Dockerfile

Co-authored-by: Alexey Milovidov <[email protected]>
Co-authored-by: Andrew Onyshchuk <[email protected]>
Co-authored-by: Artem Zuikov <[email protected]>
Co-authored-by: Alexander Kuzmenkov <[email protected]>
Co-authored-by: Alexander Kuzmenkov <[email protected]>
Co-authored-by: Anton Popov <[email protected]>
Co-authored-by: bharatnc <[email protected]>
Co-authored-by: feng lv <[email protected]>
Co-authored-by: alesapin <[email protected]>
Co-authored-by: Nikita Mikhaylov <[email protected]>
Co-authored-by: tavplubix <[email protected]>
Co-authored-by: Nikolai Kochetov <[email protected]>
Co-authored-by: Tom Bombadil <[email protected]>
Co-authored-by: Yuntao Wu <[email protected]>
Co-authored-by: BohuTANG <[email protected]>
Co-authored-by: Wang Fenjin <[email protected]>
Co-authored-by: Vitaly Baranov <[email protected]>
Co-authored-by: Mikhail Gaidamaka <[email protected]>
Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
Co-authored-by: Nikolai Kochetov <[email protected]>
Co-authored-by: Ivan Blinkov <[email protected]>
Co-authored-by: BayoNet <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Roman Bug <[email protected]>
Co-authored-by: romanzhukov <[email protected]>
Co-authored-by: Ivan <[email protected]>
Co-authored-by: Azat Khuzhin <[email protected]>
Co-authored-by: chengy8934 <[email protected]>
Co-authored-by: MicrochipQ <[email protected]>
Co-authored-by: Alexander Kazakov <[email protected]>
Co-authored-by: Vladimir Chebotarev <[email protected]>
Co-authored-by: Nicolae Vartolomei <[email protected]>
Co-authored-by: olgarev <[email protected]>
Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: AsiaKorushkina <[email protected]>
Co-authored-by: asiana21 <[email protected]>
Co-authored-by: Evgenia Sudarikova <[email protected]>
alesapin added a commit that referenced this pull request Jul 10, 2020
…ment (#12234)

* fixpu

* Update 00945_bloom_filter_index.sql

* Less layers in docker file

* Less layers in docker file

* Update docker/test/performance-comparison/perf.py

* rename test back to test.py

* client exit with unrecognized arguments

format code

fix

* remove useless const

* save

* Update canonized values in 00753_system_columns_and_system_tables.

* add ssd to integration test

* one more test

* Fix one reason of test flakiness

* Fix race condition in extractAllGroups

* extract JOIN in own plan step

* fix mistake reported by @Slach

* remove useless logic

* fix crash

* Revive mmap IO

* More verbose CMake in build docker

* Avro UUID support

* remove a trick with expression continuation

* Respect direct_io/mmap settings while reading secondary indices

* Minor modification

* Added a comment #11949

* Added a test

* Add CANNOT_PARSE_UUID extern const

* Fix estimation of the number of marks for various thresholds

* better ExpressionAction::execute()

* performance comparison

* add page fault perf events

* better error messages

* Add CPU frequencies to system.asynchronous_metrics

* Update AsynchronousMetrics.cpp

* keep ArrayJoin optimisation

* Update path to performance tests build

* tests with distributed

* place left join keys in before_join actions

* Added tests for #8692

* review fixes

* fix totals

* Update path to perf test package

* use std::filesystem::path

* Minor cleanup in Client.cpp before fuzzing

* Extend word break config to all non-alphanumeric chars

* Update AsynchronousMetrics.h

* more cleanup

* add test

update test

fix

* remove unused imports + bump tests

* Update 01345_array_join_LittleMaverick.sql

* Update ExpressionActions.h

* Fixes

* Add comment

* Remove empty lines

* Update system.md (#11945)

* Update system.md

Translate the doc to Chinese

* Update system.md

* fix the title's translattion error (#11939)

@zhang2014 I use MergeTree replaced  Chinese version "合并“, and fix an error.

* Add __init__.py

* Remove strange header

* Trying to fix ya.make

* Update replxx submodule

* Add a test for #10102

* disable tests in arcadia

* Added a test from #5131

* Try to enable long perf tests

* performance comparison

* longer

* muzzy decay 10 ms

* Support Enums type for MySQL engine #3985

* performance comparison

* Add integration test for MySQL enums type

* Fix bad log message at server startup

* Insert enum column values for test

* Better diagnostics of "Replica {} appears to be already active" message

* Fix typos

* Added a test for #8550

* Update extended-roadmap.md

* Update test

* Fix FPE, step 1

* Make it more correct

* Add a test

* Avoid floating point error in geohashesInBox #11369

* Avro: allow missing fields

* update

* Fix build

* Revert "[experiment] maybe fix warnings in integration tests"

* Add xeus-clickhouse (#12010)

xeus-clickhouse is a Jupyter kernal for ClickHouse

* Fix test

* Fix array size overflow in generateRandom

* Added a test

* Update ErrorCodes.cpp

* More hardening

* More hardening

* Fix access rights: cannot grant DDL when allow_ddl=0

* Add tests

* Add test test_allow_ddl.

* Added failing test

* Remove the usage of obsolete setting

* Whitespace

* Added a test

* Allow to ALTER partition key in some cases

* Slightly more safe

* Only allow Enum extension within the same width

* Update test

* Added failing test for Replicated table

* Fix clang-tidy

* Whitespace

* Write partition key changes to ZooKeeper

* Typos

* Implement for ReplicatedMergeTree

* Added test reference

* Added missing ORDER BY in test

* Fix integration test

* Fix error in addMonths with floating point argument

* Fix error in addMonths with floating point argument

* Fix overflow in function "neighbor"

* Whitespace

* Whitespace

* Fix ORDER BY tuple with COLLATE on const column

* clickhouse-local: logging flags fixes

* clickhouse-local: use std::filesystem::equivalent

* Limit /proc/cpuinfo metrics to linux only

* Feature 8074 (#12014)

* refs #8074 1: start to stream

* refs final check format and spell

* refs final check format and spell

* refs #8074 fix up link to sql-reference/functions/other-functions

* Bump idna from 2.9 to 2.10 in /docs/tools

Bumps [idna](https://github.com/kjd/idna) from 2.9 to 2.10.
- [Release notes](https://github.com/kjd/idna/releases)
- [Changelog](https://github.com/kjd/idna/blob/master/HISTORY.rst)
- [Commits](kjd/idna@v2.9...v2.10)

Signed-off-by: dependabot-preview[bot] <[email protected]>

* make a short test for DateTime

* DOCS-636 Synchronized some edits from EN to RU (#11941)

* [review][clickhousedocs][translate] DOCSUP-1351: Edit and translate to Russian (#129)

* DOCSUP-1351: Add blockSerializedSize (RU)

* DOCSUP-1351: Fix blockSerializedSize description by function description template.

* DOCSUP-1351: PR8756- Update Distributed engine section.

* DOCSUP-1351: PR9076-Show Queries more like MySQL did.

* DOCSUP-1351: PR#9919-system.tables improvements (total_rows/total_bytes/storage_policy)

* DOCSUP-1351: (ru) blockSerializedSize remake by template.

* DOCSUP-1351: PR#9598-Add function arrayReduceInRange and update arrayReduce function.

* DOCSUP-1351: PR#9598 Fix arrayReduce and arrayReduceInRanges sections by template.

* DOCSUP-1351: Some fixes.

* DOCSUP-1351: Some fixes.

Co-authored-by: romanzhukov <[email protected]>

* CLICKHOUSEDOCS-636: Minor changes.

Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Roman Bug <[email protected]>
Co-authored-by: romanzhukov <[email protected]>

* Temporary enable debug logs when releasing docs

* Better docker images list

* [docs] improve stable releases discovery

* Update contrib/jemalloc-cmake/CMakeLists.txt

* Automated backporting machinery (#12029)

* Add automated cherry-pick machinery

* Added script for backporting machinery

* Implement dry-run mode

* Comment old methods

* Fix python2

* Add ya.make for sandbox tasks

* Remove old stuff

* Add TLB misses perf counters.

* Update ThreadProfileEvents.cpp

* Fake change in dockerfile

* Fix tuple nullable comparison.

* Fix access rights: cannot grant INTROSPECTION when allow_introspection_functions=0.

* fixup

* Update ThreadProfileEvents.cpp

* Fix test.

* Added test.

* Fix test.

* Update ITransformingStep.h

* Remove test that is not supported by "Arcadia" build system

* Make topK return Enum for Enum types

* parse metadata in parallel when loading tables

* Update ThreadProfileEvents.cpp

* Update browse-code.md (#12047)

* Update browse-code.md

纠正了一些翻译错误。

* Update browse-code.md

Co-authored-by: Ivan Blinkov <[email protected]>

* Bump python-slugify from 1.2.6 to 4.0.1 in /docs/tools

Bumps [python-slugify](https://github.com/un33k/python-slugify) from 1.2.6 to 4.0.1.
- [Release notes](https://github.com/un33k/python-slugify/releases)
- [Changelog](https://github.com/un33k/python-slugify/blob/master/CHANGELOG.md)
- [Commits](un33k/python-slugify@1.2.6...4.0.1)

Signed-off-by: dependabot-preview[bot] <[email protected]>

* Update ThreadProfileEvents.cpp

* Update README.md

* Fix typo (#12046)

* Fix test_allow_introspection.

* Try fix labda tuple(LC) argument.

* Try fix labda tuple(LC) argument.

* Added test.

* fix low card types in merge join (#12035)

* Update contrib/poco to ClickHouse-Extras/poco #22 (#12037)

* Updated ClickHouse-Extras/poco #22

* Fix defaultValueOfArgumentType

* Added test.

* Update cpu_synthetic.xml

* Moves task shall be started if new storage policy needs them.

* Added test for automatic start of background move task.

* Fix partial revokes (complex cases).

* Changelog for 20.3.11, 12

* simple changelog script

* [blog] add RSS feed (#12064)

* [blog] add rss feed

* better title

* Update CHANGELOG.md

Co-authored-by: Ivan Blinkov <[email protected]>

* Moved useless S3 logging to TRACE level.

* DOCS-609: max_server_memory_usage (#11771)

* Revolg DOCSUP-1000 add max server memory usage setting (#125)

* Add max_server_memory_usage setting, delete max_memory_usage_for_all_queries setting.

* Syntax fixed

* Apply suggestions from code review

Co-authored-by: BayoNet <[email protected]>

* Doc for the max_server_memory_usage setting. Updates.

Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-609: Minor fixes.

* CLICKHOUSEDOCS-609: Actualized position of the setting.

Co-authored-by: olgarev <[email protected]>
Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>

* DOCS-510: runningAccumulate (#12061)

* asiana21-DOCSUP-797 (#117)

* docs(runningAccumulate): the function description is added

* docs(runningAccumulate): the function description is modified

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* docs(runningAccumulate): some changes

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* docs(runningAccumulate): added ru translation

Co-authored-by: asiana21 <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-510: Minor fix.

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: Ivan Blinkov <[email protected]>

* CLICKHOUSEDOCS-510: Fixed links.

Co-authored-by: AsiaKorushkina <[email protected]>
Co-authored-by: asiana21 <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Ivan Blinkov <[email protected]>

* [docs] Sync zh/development/build-osx.md from EN (#12071)

* DOCS-635: Translated the EN version of the AvroConfluent format description (#11930)

* DOCSUP-1350 (#128)

* edited EN version

* add EN and RU translation

* minor changes

* CLICKHOUSEDOCS-635: Updated the description.

Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Evgenia Sudarikova <[email protected]>

* DOCS-605: Description for the always_fetch_merged_part setting (#11921)

* Revolg DOCSUP-998 Document the always_fetch_merged_part setting (#123)

* Add always_fetch_merged_part setting

* revolg-DOCSUP-998-add_always_fetch_merged_part_setting link fixed

* Apply suggestions from code review

Co-authored-by: BayoNet <[email protected]>

* Add always_fetch_merged_part setting. Updates.

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* Add always_fetch_merged_part setting. Updates.

Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-605: Minor fixes.

* CLICKHOUSEDOCS-605: Added Plausible to Adopters.

* Update docs/ru/operations/settings/settings.md

Co-authored-by: alesapin <[email protected]>

* Update docs/en/operations/settings/settings.md

Co-authored-by: alesapin <[email protected]>

* CLICKHOUSEDOCS-605: Fixed access rights description.

Co-authored-by: olgarev <[email protected]>
Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: alesapin <[email protected]>

* Update Dockerfile

* revert e9d3c48

* [blog] 'Package Repository Behind CDN' post (#12082)

* support iframes from DataLens

* initial blog post text

Co-authored-by: Alexander Kuzmenkov <[email protected]>
Co-authored-by: tavplubix <[email protected]>
Co-authored-by: BohuTANG <[email protected]>
Co-authored-by: Alexander Kuzmenkov <[email protected]>
Co-authored-by: Ivan Blinkov <[email protected]>
Co-authored-by: alesapin <[email protected]>
Co-authored-by: feng lv <[email protected]>
Co-authored-by: Nikita Mikhaylov <[email protected]>
Co-authored-by: Anton Popov <[email protected]>
Co-authored-by: alexey-milovidov <[email protected]>
Co-authored-by: Maxim Akhmedov <[email protected]>
Co-authored-by: Nikita Mikhailov <[email protected]>
Co-authored-by: Artem Zuikov <[email protected]>
Co-authored-by: Andrew Onyshchuk <[email protected]>
Co-authored-by: bharatnc <[email protected]>
Co-authored-by: Nikolai Kochetov <[email protected]>
Co-authored-by: Tom Bombadil <[email protected]>
Co-authored-by: Yuntao Wu <[email protected]>
Co-authored-by: Wang Fenjin <[email protected]>
Co-authored-by: Vitaly Baranov <[email protected]>
Co-authored-by: Mikhail Gaidamaka <[email protected]>
Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
Co-authored-by: Nikolai Kochetov <[email protected]>
Co-authored-by: BayoNet <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Roman Bug <[email protected]>
Co-authored-by: romanzhukov <[email protected]>
Co-authored-by: Ivan <[email protected]>
Co-authored-by: chengy8934 <[email protected]>
Co-authored-by: MicrochipQ <[email protected]>
Co-authored-by: Alexander Kazakov <[email protected]>
Co-authored-by: Vladimir Chebotarev <[email protected]>
Co-authored-by: olgarev <[email protected]>
Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: AsiaKorushkina <[email protected]>
Co-authored-by: asiana21 <[email protected]>
Co-authored-by: Evgenia Sudarikova <[email protected]>
alesapin added a commit that referenced this pull request Jul 10, 2020
* fix some logical errors

* Update features.html

* Consider allocatedBytes() instead of bytes() in Storage{Buffer,Memory}.

* fix query parameter visitor

* fixpu

* Update 00945_bloom_filter_index.sql

* Less layers in docker file

* Less layers in docker file

* Update docker/test/performance-comparison/perf.py

* rename test back to test.py

* client exit with unrecognized arguments

format code

fix

* remove useless const

* save

* Update canonized values in 00753_system_columns_and_system_tables.

* add ssd to integration test

* one more test

* Fix one reason of test flakiness

* Fix race condition in extractAllGroups

* extract JOIN in own plan step

* fix mistake reported by @Slach

* remove useless logic

* fix crash

* Revive mmap IO

* More verbose CMake in build docker

* Avro UUID support

* remove a trick with expression continuation

* Respect direct_io/mmap settings while reading secondary indices

* Minor modification

* Added a comment #11949

* Added a test

* Add CANNOT_PARSE_UUID extern const

* Fix estimation of the number of marks for various thresholds

* better ExpressionAction::execute()

* performance comparison

* add page fault perf events

* better error messages

* Add CPU frequencies to system.asynchronous_metrics

* Update AsynchronousMetrics.cpp

* keep ArrayJoin optimisation

* Update path to performance tests build

* tests with distributed

* place left join keys in before_join actions

* Added tests for #8692

* review fixes

* fix totals

* Update path to perf test package

* use std::filesystem::path

* Minor cleanup in Client.cpp before fuzzing

* Extend word break config to all non-alphanumeric chars

* Update AsynchronousMetrics.h

* more cleanup

* add test

update test

fix

* remove unused imports + bump tests

* Update 01345_array_join_LittleMaverick.sql

* Update ExpressionActions.h

* Fixes

* Add comment

* Remove empty lines

* Update system.md (#11945)

* Update system.md

Translate the doc to Chinese

* Update system.md

* fix the title's translattion error (#11939)

@zhang2014 I use MergeTree replaced  Chinese version "合并“, and fix an error.

* Add __init__.py

* Remove strange header

* Trying to fix ya.make

* Update replxx submodule

* Add a test for #10102

* disable tests in arcadia

* Added a test from #5131

* Try to enable long perf tests

* performance comparison

* longer

* muzzy decay 10 ms

* Support Enums type for MySQL engine #3985

* performance comparison

* Add integration test for MySQL enums type

* Fix bad log message at server startup

* Insert enum column values for test

* Better diagnostics of "Replica {} appears to be already active" message

* Fix typos

* Added a test for #8550

* Update extended-roadmap.md

* Update test

* Fix FPE, step 1

* Make it more correct

* Add a test

* Avoid floating point error in geohashesInBox #11369

* Avro: allow missing fields

* update

* Fix build

* Revert "[experiment] maybe fix warnings in integration tests"

* Add xeus-clickhouse (#12010)

xeus-clickhouse is a Jupyter kernal for ClickHouse

* Fix test

* Fix array size overflow in generateRandom

* Added a test

* Update ErrorCodes.cpp

* More hardening

* More hardening

* Fix access rights: cannot grant DDL when allow_ddl=0

* Add tests

* Add test test_allow_ddl.

* Added failing test

* Remove the usage of obsolete setting

* Whitespace

* Added a test

* Allow to ALTER partition key in some cases

* Slightly more safe

* Only allow Enum extension within the same width

* Update test

* Added failing test for Replicated table

* Fix clang-tidy

* Whitespace

* Write partition key changes to ZooKeeper

* Typos

* Implement for ReplicatedMergeTree

* Added test reference

* Added missing ORDER BY in test

* Fix integration test

* Fix error in addMonths with floating point argument

* Fix error in addMonths with floating point argument

* Fix overflow in function "neighbor"

* Whitespace

* Whitespace

* Fix ORDER BY tuple with COLLATE on const column

* clickhouse-local: logging flags fixes

* clickhouse-local: use std::filesystem::equivalent

* Limit /proc/cpuinfo metrics to linux only

* Feature 8074 (#12014)

* refs #8074 1: start to stream

* refs final check format and spell

* refs final check format and spell

* refs #8074 fix up link to sql-reference/functions/other-functions

* Bump idna from 2.9 to 2.10 in /docs/tools

Bumps [idna](https://github.com/kjd/idna) from 2.9 to 2.10.
- [Release notes](https://github.com/kjd/idna/releases)
- [Changelog](https://github.com/kjd/idna/blob/master/HISTORY.rst)
- [Commits](kjd/idna@v2.9...v2.10)

Signed-off-by: dependabot-preview[bot] <[email protected]>

* make a short test for DateTime

* DOCS-636 Synchronized some edits from EN to RU (#11941)

* [review][clickhousedocs][translate] DOCSUP-1351: Edit and translate to Russian (#129)

* DOCSUP-1351: Add blockSerializedSize (RU)

* DOCSUP-1351: Fix blockSerializedSize description by function description template.

* DOCSUP-1351: PR8756- Update Distributed engine section.

* DOCSUP-1351: PR9076-Show Queries more like MySQL did.

* DOCSUP-1351: PR#9919-system.tables improvements (total_rows/total_bytes/storage_policy)

* DOCSUP-1351: (ru) blockSerializedSize remake by template.

* DOCSUP-1351: PR#9598-Add function arrayReduceInRange and update arrayReduce function.

* DOCSUP-1351: PR#9598 Fix arrayReduce and arrayReduceInRanges sections by template.

* DOCSUP-1351: Some fixes.

* DOCSUP-1351: Some fixes.

Co-authored-by: romanzhukov <[email protected]>

* CLICKHOUSEDOCS-636: Minor changes.

Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Roman Bug <[email protected]>
Co-authored-by: romanzhukov <[email protected]>

* Temporary enable debug logs when releasing docs

* Better docker images list

* [docs] improve stable releases discovery

* Update contrib/jemalloc-cmake/CMakeLists.txt

* Automated backporting machinery (#12029)

* Add automated cherry-pick machinery

* Added script for backporting machinery

* Implement dry-run mode

* Comment old methods

* Fix python2

* Add ya.make for sandbox tasks

* Remove old stuff

* Add TLB misses perf counters.

* Update ThreadProfileEvents.cpp

* Fake change in dockerfile

* Fix tuple nullable comparison.

* Fix access rights: cannot grant INTROSPECTION when allow_introspection_functions=0.

* fixup

* Update ThreadProfileEvents.cpp

* Fix test.

* Added test.

* Fix test.

* Update ITransformingStep.h

* Remove test that is not supported by "Arcadia" build system

* Make topK return Enum for Enum types

* parse metadata in parallel when loading tables

* Update ThreadProfileEvents.cpp

* Update browse-code.md (#12047)

* Update browse-code.md

纠正了一些翻译错误。

* Update browse-code.md

Co-authored-by: Ivan Blinkov <[email protected]>

* Bump python-slugify from 1.2.6 to 4.0.1 in /docs/tools

Bumps [python-slugify](https://github.com/un33k/python-slugify) from 1.2.6 to 4.0.1.
- [Release notes](https://github.com/un33k/python-slugify/releases)
- [Changelog](https://github.com/un33k/python-slugify/blob/master/CHANGELOG.md)
- [Commits](un33k/python-slugify@1.2.6...4.0.1)

Signed-off-by: dependabot-preview[bot] <[email protected]>

* Update ThreadProfileEvents.cpp

* Update README.md

* Fix typo (#12046)

* Fix test_allow_introspection.

* fix low card types in merge join (#12035)

* Update contrib/poco to ClickHouse-Extras/poco #22 (#12037)

* Updated ClickHouse-Extras/poco #22

* Fix defaultValueOfArgumentType

* Added test.

* Update cpu_synthetic.xml

* Moves task shall be started if new storage policy needs them.

* Added test for automatic start of background move task.

* Fix partial revokes (complex cases).

* Changelog for 20.3.11, 12

* simple changelog script

* [blog] add RSS feed (#12064)

* [blog] add rss feed

* better title

* Update CHANGELOG.md

Co-authored-by: Ivan Blinkov <[email protected]>

* Moved useless S3 logging to TRACE level.

* DOCS-609: max_server_memory_usage (#11771)

* Revolg DOCSUP-1000 add max server memory usage setting (#125)

* Add max_server_memory_usage setting, delete max_memory_usage_for_all_queries setting.

* Syntax fixed

* Apply suggestions from code review

Co-authored-by: BayoNet <[email protected]>

* Doc for the max_server_memory_usage setting. Updates.

Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-609: Minor fixes.

* CLICKHOUSEDOCS-609: Actualized position of the setting.

Co-authored-by: olgarev <[email protected]>
Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>

* DOCS-510: runningAccumulate (#12061)

* asiana21-DOCSUP-797 (#117)

* docs(runningAccumulate): the function description is added

* docs(runningAccumulate): the function description is modified

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* docs(runningAccumulate): some changes

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: BayoNet <[email protected]>

* docs(runningAccumulate): added ru translation

Co-authored-by: asiana21 <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-510: Minor fix.

* Update docs/en/sql-reference/functions/other-functions.md

Co-authored-by: Ivan Blinkov <[email protected]>

* CLICKHOUSEDOCS-510: Fixed links.

Co-authored-by: AsiaKorushkina <[email protected]>
Co-authored-by: asiana21 <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Ivan Blinkov <[email protected]>

* [docs] Sync zh/development/build-osx.md from EN (#12071)

* DOCS-635: Translated the EN version of the AvroConfluent format description (#11930)

* DOCSUP-1350 (#128)

* edited EN version

* add EN and RU translation

* minor changes

* CLICKHOUSEDOCS-635: Updated the description.

Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Evgenia Sudarikova <[email protected]>

* DOCS-605: Description for the always_fetch_merged_part setting (#11921)

* Revolg DOCSUP-998 Document the always_fetch_merged_part setting (#123)

* Add always_fetch_merged_part setting

* revolg-DOCSUP-998-add_always_fetch_merged_part_setting link fixed

* Apply suggestions from code review

Co-authored-by: BayoNet <[email protected]>

* Add always_fetch_merged_part setting. Updates.

* Update docs/en/operations/settings/settings.md

Co-authored-by: BayoNet <[email protected]>

* Add always_fetch_merged_part setting. Updates.

Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: BayoNet <[email protected]>

* CLICKHOUSEDOCS-605: Minor fixes.

* CLICKHOUSEDOCS-605: Added Plausible to Adopters.

* Update docs/ru/operations/settings/settings.md

Co-authored-by: alesapin <[email protected]>

* Update docs/en/operations/settings/settings.md

Co-authored-by: alesapin <[email protected]>

* CLICKHOUSEDOCS-605: Fixed access rights description.

Co-authored-by: olgarev <[email protected]>
Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: alesapin <[email protected]>

* Update Dockerfile

* revert e9d3c48

* [blog] 'Package Repository Behind CDN' post (#12082)

* support iframes from DataLens

* initial blog post text

Co-authored-by: Alexander Tokmakov <[email protected]>
Co-authored-by: Ivan Blinkov <[email protected]>
Co-authored-by: Maxim Akhmedov <[email protected]>
Co-authored-by: Alexander Kuzmenkov <[email protected]>
Co-authored-by: BohuTANG <[email protected]>
Co-authored-by: Alexander Kuzmenkov <[email protected]>
Co-authored-by: alesapin <[email protected]>
Co-authored-by: feng lv <[email protected]>
Co-authored-by: Nikita Mikhaylov <[email protected]>
Co-authored-by: Anton Popov <[email protected]>
Co-authored-by: alexey-milovidov <[email protected]>
Co-authored-by: Nikita Mikhailov <[email protected]>
Co-authored-by: Artem Zuikov <[email protected]>
Co-authored-by: Andrew Onyshchuk <[email protected]>
Co-authored-by: bharatnc <[email protected]>
Co-authored-by: Nikolai Kochetov <[email protected]>
Co-authored-by: Tom Bombadil <[email protected]>
Co-authored-by: Yuntao Wu <[email protected]>
Co-authored-by: Wang Fenjin <[email protected]>
Co-authored-by: Vitaly Baranov <[email protected]>
Co-authored-by: Mikhail Gaidamaka <[email protected]>
Co-authored-by: dependabot-preview[bot] <27856297+dependabot-preview[bot]@users.noreply.github.com>
Co-authored-by: Nikolai Kochetov <[email protected]>
Co-authored-by: BayoNet <[email protected]>
Co-authored-by: Sergei Shtykov <[email protected]>
Co-authored-by: Roman Bug <[email protected]>
Co-authored-by: romanzhukov <[email protected]>
Co-authored-by: Ivan <[email protected]>
Co-authored-by: chengy8934 <[email protected]>
Co-authored-by: MicrochipQ <[email protected]>
Co-authored-by: Alexander Kazakov <[email protected]>
Co-authored-by: Vladimir Chebotarev <[email protected]>
Co-authored-by: olgarev <[email protected]>
Co-authored-by: Olga Revyakina <[email protected]>
Co-authored-by: AsiaKorushkina <[email protected]>
Co-authored-by: asiana21 <[email protected]>
Co-authored-by: Evgenia Sudarikova <[email protected]>
azat added a commit to azat/ClickHouse that referenced this pull request Sep 1, 2020
…h nested interpreter

Example of such queries are distributed queries, which creates local
InterpreterSelectQuery, which will have it's own QueryPlan but returns
Pipes that has that IQueryPlanStep attached.

After EXPLAIN PIPELINE graph=1 tries to use them, and will get SIGSEGV.

- TSAN:

<details>

```
==2782113==ERROR: AddressSanitizer: heap-use-after-free on address 0x6120000223c0 at pc 0x00002b8f3f3e bp 0x7fff18cfbff0 sp 0x7fff18cfbfe8
READ of size 8 at 0x6120000223c0 thread T22 (TCPHandler)
    #0 0x2b8f3f3d in DB::printPipelineCompact(std::__1::vector<std::__1::shared_ptr<DB::IProcessor>, std::__1::allocator<std::__1::shared_ptr<DB::IProcessor> > > const&, DB::WriteBuffer&, bool) /build/obj-x86_64-linux-gnu/../src/Processors/printPipeline.cpp:116:53
    ClickHouse#1 0x29ee698c in DB::InterpreterExplainQuery::executeImpl() /build/obj-x86_64-linux-gnu/../src/Interpreters/InterpreterExplainQuery.cpp:275:17
    ClickHouse#2 0x29ee2e40 in DB::InterpreterExplainQuery::execute() /build/obj-x86_64-linux-gnu/../src/Interpreters/InterpreterExplainQuery.cpp:73:14
    ClickHouse#3 0x2a7b44a2 in DB::executeQueryImpl(char const*, char const*, DB::Context&, bool, DB::QueryProcessingStage::Enum, bool, DB::ReadBuffer*) /build/obj-x86_64-linux-gnu/../src/Interpreters/executeQuery.cpp:389:28
    ClickHouse#4 0x2a7b1cb3 in DB::executeQuery(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, DB::Context&, bool, DB::QueryProcessingStage::Enum, bool) /build/obj-x86_64-linux-gnu/../src/Interpreters/executeQuery.cpp:675:30
    ClickHouse#5 0x2b7993b2 in DB::TCPHandler::runImpl() /build/obj-x86_64-linux-gnu/../src/Server/TCPHandler.cpp:253:24
    ClickHouse#6 0x2b7b649a in DB::TCPHandler::run() /build/obj-x86_64-linux-gnu/../src/Server/TCPHandler.cpp:1217:9
    ClickHouse#7 0x31d9c57e in Poco::Net::TCPServerConnection::start() /build/obj-x86_64-linux-gnu/../contrib/poco/Net/src/TCPServerConnection.cpp:43:3
    ClickHouse#8 0x31d9d281 in Poco::Net::TCPServerDispatcher::run() /build/obj-x86_64-linux-gnu/../contrib/poco/Net/src/TCPServerDispatcher.cpp:114:20
    ClickHouse#9 0x3206b5d5 in Poco::PooledThread::run() /build/obj-x86_64-linux-gnu/../contrib/poco/Foundation/src/ThreadPool.cpp:199:14
    ClickHouse#10 0x320657ad in Poco::ThreadImpl::runnableEntry(void*) /build/obj-x86_64-linux-gnu/../contrib/poco/Foundation/src/Thread_POSIX.cpp:345:27
    ClickHouse#11 0x7ffff7f853e8 in start_thread (/usr/lib/libpthread.so.0+0x93e8)
    ClickHouse#12 0x7ffff7ea2292 in clone (/usr/lib/libc.so.6+0x100292)

0x6120000223c0 is located 0 bytes inside of 272-byte region [0x6120000223c0,0x6120000224d0)
freed by thread T22 (TCPHandler) here:
    #0 0x122f3b62 in operator delete(void*, unsigned long) (/src/ch/tmp/master-20200831/clickhouse+0x122f3b62)
    ClickHouse#1 0x2bd9e9fa in std::__1::default_delete<DB::IQueryPlanStep>::operator()(DB::IQueryPlanStep*) const /build/obj-x86_64-linux-gnu/../contrib/libcxx/include/memory:2363:5
    ClickHouse#2 0x2bd9e9fa in std::__1::unique_ptr<DB::IQueryPlanStep, std::__1::default_delete<DB::IQueryPlanStep> >::reset(DB::IQueryPlanStep*) /build/obj-x86_64-linux-gnu/../contrib/libcxx/include/memory:2618:7
    ClickHouse#3 0x2bd9e9fa in std::__1::unique_ptr<DB::IQueryPlanStep, std::__1::default_delete<DB::IQueryPlanStep> >::~unique_ptr() /build/obj-x86_64-linux-gnu/../contrib/libcxx/include/memory:2572:19
    ClickHouse#4 0x2bd9e9fa in DB::QueryPlan::Node::~Node() /build/obj-x86_64-linux-gnu/../src/Processors/QueryPlan/QueryPlan.h:66:12
    ClickHouse#5 0x2bd9e9fa in void std::__1::allocator_traits<std::__1::allocator<std::__1::__list_node<DB::QueryPlan::Node, void*> > >::__destroy<DB::QueryPlan::Node>(std::__1::integral_constant<bool, false>, std::__1::allocator<std::__1::__list_node<DB::QueryPlan::Node, void*> >&,
 DB::QueryPlan::Node*) /build/obj-x86_64-linux-gnu/../contrib/libcxx/include/memory:1798:23
    ClickHouse#6 0x2bd9e9fa in void std::__1::allocator_traits<std::__1::allocator<std::__1::__list_node<DB::QueryPlan::Node, void*> > >::destroy<DB::QueryPlan::Node>(std::__1::allocator<std::__1::__list_node<DB::QueryPlan::Node, void*> >&, DB::QueryPlan::Node*) /build/obj-x86_64-lin
ux-gnu/../contrib/libcxx/include/memory:1630:14
    ClickHouse#7 0x2bd9e9fa in std::__1::__list_imp<DB::QueryPlan::Node, std::__1::allocator<DB::QueryPlan::Node> >::clear() /build/obj-x86_64-linux-gnu/../contrib/libcxx/include/list:762:13
    ClickHouse#8 0x29fece08 in DB::InterpreterSelectQuery::execute() /build/obj-x86_64-linux-gnu/../src/Interpreters/InterpreterSelectQuery.cpp:492:1
    ClickHouse#9 0x2abf7484 in DB::ClusterProxy::(anonymous namespace)::createLocalStream(std::__1::shared_ptr<DB::IAST> const&, DB::Block const&, DB::Context const&, DB::QueryProcessingStage::Enum) /build/obj-x86_64-linux-gnu/../src/Interpreters/ClusterProxy/SelectStreamFactory.cpp:
78:33
    ClickHouse#10 0x2abea85d in DB::ClusterProxy::SelectStreamFactory::createForShard(DB::Cluster::ShardInfo const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, std::__1::shared_ptr<DB::IAST> const&, DB::Context const&, std::__1::shar
ed_ptr<DB::Throttler> const&, DB::SelectQueryInfo const&, std::__1::vector<DB::Pipe, std::__1::allocator<DB::Pipe> >&)::$_0::operator()() const /build/obj-x86_64-linux-gnu/../src/Interpreters/ClusterProxy/SelectStreamFactory.cpp:133:51
    ClickHouse#11 0x2abea85d in DB::ClusterProxy::SelectStreamFactory::createForShard(DB::Cluster::ShardInfo const&, std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, std::__1::shared_ptr<DB::IAST> const&, DB::Context const&, std::__1::shar
ed_ptr<DB::Throttler> const&, DB::SelectQueryInfo const&, std::__1::vector<DB::Pipe, std::__1::allocator<DB::Pipe> >&) /build/obj-x86_64-linux-gnu/../src/Interpreters/ClusterProxy/SelectStreamFactory.cpp:189:13
    ClickHouse#12 0x2abe6d99 in DB::ClusterProxy::executeQuery(DB::ClusterProxy::IStreamFactory&, std::__1::shared_ptr<DB::Cluster> const&, Poco::Logger*, std::__1::shared_ptr<DB::IAST> const&, DB::Context const&, DB::Settings const&, DB::SelectQueryInfo const&) /build/obj-x86_64-lin
ux-gnu/../src/Interpreters/ClusterProxy/executeQuery.cpp:107:24
    ClickHouse#13 0x2abc4b74 in DB::StorageDistributed::read(std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, s
td::__1::shared_ptr<DB::StorageInMemoryMetadata const> const&, DB::SelectQueryInfo const&, DB::Context const&, DB::QueryProcessingStage::Enum, unsigned long, unsigned int) /build/obj-x86_64-linux-gnu/../src/Storages/StorageDistributed.cpp:514:12
    ClickHouse#14 0x2bda1c5a in DB::ReadFromStorageStep::ReadFromStorageStep(std::__1::shared_ptr<DB::RWLockImpl::LockHolderImpl>, std::__1::shared_ptr<DB::StorageInMemoryMetadata const>&, DB::SelectQueryOptions, std::__1::shared_ptr<DB::IStorage>, std::__1::vector<std::__1::basic_st
ring<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&, DB::SelectQueryInfo const&, std::__1::shared_ptr<DB::Context>, DB::QueryProcessingStage
::Enum, unsigned long, unsigned long) /build/obj-x86_64-linux-gnu/../src/Processors/QueryPlan/ReadFromStorageStep.cpp:39:26
    ClickHouse#15 0x2a01ca70 in std::__1::__unique_if<DB::ReadFromStorageStep>::__unique_single std::__1::make_unique<DB::ReadFromStorageStep, std::__1::shared_ptr<DB::RWLockImpl::LockHolderImpl>&, std::__1::shared_ptr<DB::StorageInMemoryMetadata const>&, DB::SelectQueryOptions&, std
::__1::shared_ptr<DB::IStorage>&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > >&, DB::SelectQueryInfo&, st
d::__1::shared_ptr<DB::Context>&, DB::QueryProcessingStage::Enum&, unsigned long&, unsigned long&>(std::__1::shared_ptr<DB::RWLockImpl::LockHolderImpl>&, std::__1::shared_ptr<DB::StorageInMemoryMetadata const>&, DB::SelectQueryOptions&, std::__1::shared_ptr<DB::IStorage>&,
std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > >&, DB::SelectQueryInfo&, std::__1::shared_ptr<DB::Context>&,
DB::QueryProcessingStage::Enum&, unsigned long&, unsigned long&) /build/obj-x86_64-linux-gnu/../contrib/libcxx/include/memory:3028:32
    ClickHouse#16 0x29ff556a in DB::InterpreterSelectQuery::executeFetchColumns(DB::QueryProcessingStage::Enum, DB::QueryPlan&, std::__1::shared_ptr<DB::PrewhereInfo> const&, std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::
__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&) /build/obj-x86_64-linux-gnu/../src/Interpreters/InterpreterSelectQuery.cpp:1383:26
    ClickHouse#17 0x29fe6b83 in DB::InterpreterSelectQuery::executeImpl(DB::QueryPlan&, std::__1::shared_ptr<DB::IBlockInputStream> const&, std::__1::optional<DB::Pipe>) /build/obj-x86_64-linux-gnu/../src/Interpreters/InterpreterSelectQuery.cpp:795:9
    ClickHouse#18 0x29fe5771 in DB::InterpreterSelectQuery::buildQueryPlan(DB::QueryPlan&) /build/obj-x86_64-linux-gnu/../src/Interpreters/InterpreterSelectQuery.cpp:473:5
    ClickHouse#19 0x2a47d370 in DB::InterpreterSelectWithUnionQuery::buildQueryPlan(DB::QueryPlan&) /build/obj-x86_64-linux-gnu/../src/Interpreters/InterpreterSelectWithUnionQuery.cpp:182:38
    ClickHouse#20 0x29ee5bff in DB::InterpreterExplainQuery::executeImpl() /build/obj-x86_64-linux-gnu/../src/Interpreters/InterpreterExplainQuery.cpp:265:21
    ClickHouse#21 0x29ee2e40 in DB::InterpreterExplainQuery::execute() /build/obj-x86_64-linux-gnu/../src/Interpreters/InterpreterExplainQuery.cpp:73:14
    ClickHouse#22 0x2a7b44a2 in DB::executeQueryImpl(char const*, char const*, DB::Context&, bool, DB::QueryProcessingStage::Enum, bool, DB::ReadBuffer*) /build/obj-x86_64-linux-gnu/../src/Interpreters/executeQuery.cpp:389:28
    ClickHouse#23 0x2a7b1cb3 in DB::executeQuery(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const&, DB::Context&, bool, DB::QueryProcessingStage::Enum, bool) /build/obj-x86_64-linux-gnu/../src/Interpreters/executeQuery.cpp:675:30
    ClickHouse#24 0x2b7993b2 in DB::TCPHandler::runImpl() /build/obj-x86_64-linux-gnu/../src/Server/TCPHandler.cpp:253:24
    ClickHouse#25 0x2b7b649a in DB::TCPHandler::run() /build/obj-x86_64-linux-gnu/../src/Server/TCPHandler.cpp:1217:9
    ClickHouse#26 0x31d9c57e in Poco::Net::TCPServerConnection::start() /build/obj-x86_64-linux-gnu/../contrib/poco/Net/src/TCPServerConnection.cpp:43:3
    ClickHouse#27 0x31d9d281 in Poco::Net::TCPServerDispatcher::run() /build/obj-x86_64-linux-gnu/../contrib/poco/Net/src/TCPServerDispatcher.cpp:114:20
    ClickHouse#28 0x3206b5d5 in Poco::PooledThread::run() /build/obj-x86_64-linux-gnu/../contrib/poco/Foundation/src/ThreadPool.cpp:199:14
    ClickHouse#29 0x320657ad in Poco::ThreadImpl::runnableEntry(void*) /build/obj-x86_64-linux-gnu/../contrib/poco/Foundation/src/Thread_POSIX.cpp:345:27
    ClickHouse#30 0x7ffff7f853e8 in start_thread (/usr/lib/libpthread.so.0+0x93e8)
```

</details>
azat added a commit to azat/ClickHouse that referenced this pull request Nov 14, 2020
Since onCancel() and generate() can be called from different threads

TSAN reports:

    WARNING: ThreadSanitizer: data race (pid=253)
      Write of size 1 at 0x7b50008c25c2 by thread T144 (mutexes: write M643587328754916744):
        #0 DB::RemoteSource::onCancel() /build/obj-x86_64-linux-gnu/../src/Processors/Sources/RemoteSource.cpp:79:24 (clickhouse+0x11c2019d)
        ClickHouse#1 DB::IProcessor::cancel() /build/obj-x86_64-linux-gnu/../src/Processors/IProcessor.h:235:9 (clickhouse+0x11c21def)
        ClickHouse#2 DB::RemoteSource::onUpdatePorts() /build/obj-x86_64-linux-gnu/../src/Processors/Sources/RemoteSource.h:32:13 (clickhouse+0x11c21def)
        ClickHouse#3 DB::PipelineExecutor::tryAddProcessorToStackIfUpdated(DB::ExecutingGraph::Edge&, std::__1::queue<DB::ExecutingGraph::Node*, std::__1::deque<DB::ExecutingGraph::Node*, std::__1::allocator<DB::ExecutingGraph::Node*> > >&, unsigned long) /build/obj-x86_64-linux-gnu/../src/Processors/Executors/PipelineExecutor.cpp:190:43 (clickhouse+0x11aaf954)
        ClickHouse#4 DB::PipelineExecutor::prepareProcessor(unsigned long, unsigned long, std::__1::queue<DB::ExecutingGraph::Node*, std::__1::deque<DB::ExecutingGraph::Node*, std::__1::allocator<DB::ExecutingGraph::Node*> > >&, std::__1::unique_lock<std::__1::mutex>) /build/obj-x86_64-linux-gnu/../src/Processors/Executors/PipelineExecutor.cpp:296:18 (clickhouse+0x11ab0169)
        ClickHouse#5 DB::PipelineExecutor::tryAddProcessorToStackIfUpdated(DB::ExecutingGraph::Edge&, std::__1::queue<DB::ExecutingGraph::Node*, std::__1::deque<DB::ExecutingGraph::Node*, std::__1::allocator<DB::ExecutingGraph::Node*> > >&, unsigned long) /build/obj-x86_64-linux-gnu/../src/Processors/Executors/PipelineExecutor.cpp:187:16 (clickhouse+0x11aaf9c2)
        ClickHouse#6 DB::PipelineExecutor::prepareProcessor(unsigned long, unsigned long, std::__1::queue<DB::ExecutingGraph::Node*, std::__1::deque<DB::ExecutingGraph::Node*, std::__1::allocator<DB::ExecutingGraph::Node*> > >&, std::__1::unique_lock<std::__1::mutex>) /build/obj-x86_64-linux-gnu/../src/Processors/Executors/PipelineExecutor.cpp:296:18 (clickhouse+0x11ab0169)
        ClickHouse#7 DB::PipelineExecutor::executeStepImpl(unsigned long, unsigned long, std::__1::atomic<bool>*) /build/obj-x86_64-linux-gnu/../src/Processors/Executors/PipelineExecutor.cpp:589:26 (clickhouse+0x11ab2a3e)
        ClickHouse#8 DB::PipelineExecutor::executeSingleThread(unsigned long, unsigned long) /build/obj-x86_64-linux-gnu/../src/Processors/Executors/PipelineExecutor.cpp:477:5 (clickhouse+0x11ab538b)
        ClickHouse#9 DB::PipelineExecutor::executeImpl(unsigned long)::$_4::operator()() const /build/obj-x86_64-linux-gnu/../src/Processors/Executors/PipelineExecutor.cpp:736:21 (clickhouse+0x11ab538b)
        ClickHouse#10 decltype(std::__1::forward<DB::PipelineExecutor::executeImpl(unsigned long)::$_4&>(fp)()) std::__1::__invoke_constexpr<DB::PipelineExecutor::executeImpl(unsigned long)::$_4&>(DB::PipelineExecutor::executeImpl(unsigned long)::$_4&) /build/obj-x86_64-linux-gnu/../contrib/libcxx/include/type_traits:3525:1 (clickhouse+0x11ab538b)
        ClickHouse#11 decltype(auto) std::__1::__apply_tuple_impl<DB::PipelineExecutor::executeImpl(unsigned long)::$_4&, std::__1::tuple<>&>(DB::PipelineExecutor::executeImpl(unsigned long)::$_4&, std::__1::tuple<>&, std::__1::__tuple_indices<>) /build/obj-x86_64-linux-gnu/../contrib/libcxx/include/tuple:1415:1 (clickhouse+0x11ab538b)
        ClickHouse#12 decltype(auto) std::__1::apply<DB::PipelineExecutor::executeImpl(unsigned long)::$_4&, std::__1::tuple<>&>(DB::PipelineExecutor::executeImpl(unsigned long)::$_4&, std::__1::tuple<>&) /build/obj-x86_64-linux-gnu/../contrib/libcxx/include/tuple:1424:1 (clickhouse+0x11ab538b)
        ClickHouse#13 ThreadFromGlobalPool::ThreadFromGlobalPool<DB::PipelineExecutor::executeImpl(unsigned long)::$_4>(DB::PipelineExecutor::executeImpl(unsigned long)::$_4&&)::'lambda'()::operator()() /build/obj-x86_64-linux-gnu/../src/Common/ThreadPool.h:178:13 (clickhouse+0x11ab538b)
        ClickHouse#14 decltype(std::__1::forward<DB::PipelineExecutor::executeImpl(unsigned long)::$_4>(fp)()) std::__1::__invoke<ThreadFromGlobalPool::ThreadFromGlobalPool<DB::PipelineExecutor::executeImpl(unsigned long)::$_4>(DB::PipelineExecutor::executeImpl(unsigned long)::$_4&&)::'lambda'()&>(DB::PipelineExecutor::executeImpl(unsigned long)::$_4&&) /build/obj-x86_64-linux-gnu/../contrib/libcxx/include/type_traits:3519:1 (clickhouse+0x11ab538b)
        ClickHouse#15 void std::__1::__invoke_void_return_wrapper<void>::__call<ThreadFromGlobalPool::ThreadFromGlobalPool<DB::PipelineExecutor::executeImpl(unsigned long)::$_4>(DB::PipelineExecutor::executeImpl(unsigned long)::$_4&&)::'lambda'()&>(DB::PipelineExecutor::executeImpl(unsigned long)::$_4&&...) /build/obj-x86_64-linux-gnu/../contrib/libcxx/include/__functional_base:348:9 (clickhouse+0x11ab538b)
        ClickHouse#16 std::__1::__function::__alloc_func<ThreadFromGlobalPool::ThreadFromGlobalPool<DB::PipelineExecutor::executeImpl(unsigned long)::$_4>(DB::PipelineExecutor::executeImpl(unsigned long)::$_4&&)::'lambda'(), std::__1::allocator<ThreadFromGlobalPool::ThreadFromGlobalPool<DB::PipelineExecutor::executeImpl(unsigned long)::$_4>(DB::PipelineExecutor::executeImpl(unsigned long)::$_4&&)::'lambda'()>, void ()>::operator()() /build/obj-x86_64-linux-gnu/../contrib/libcxx/include/functional:1540:16 (clickhouse+0x11ab538b)
        ClickHouse#17 std::__1::__function::__func<ThreadFromGlobalPool::ThreadFromGlobalPool<DB::PipelineExecutor::executeImpl(unsigned long)::$_4>(DB::PipelineExecutor::executeImpl(unsigned long)::$_4&&)::'lambda'(), std::__1::allocator<ThreadFromGlobalPool::ThreadFromGlobalPool<DB::PipelineExecutor::executeImpl(unsigned long)::$_4>(DB::PipelineExecutor::executeImpl(unsigned long)::$_4&&)::'lambda'()>, void ()>::operator()() /build/obj-x86_64-linux-gnu/../contrib/libcxx/include/functional:1714:12 (clickhouse+0x11ab538b)
        ClickHouse#18 std::__1::__function::__value_func<void ()>::operator()() const /build/obj-x86_64-linux-gnu/../contrib/libcxx/include/functional:1867:16 (clickhouse+0x8346263)
        ClickHouse#19 std::__1::function<void ()>::operator()() const /build/obj-x86_64-linux-gnu/../contrib/libcxx/include/functional:2473:12 (clickhouse+0x8346263)
        ClickHouse#20 ThreadPoolImpl<std::__1::thread>::worker(std::__1::__list_iterator<std::__1::thread, void*>) /build/obj-x86_64-linux-gnu/../src/Common/ThreadPool.cpp:236:17 (clickhouse+0x8346263)
        ClickHouse#21 void ThreadPoolImpl<std::__1::thread>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()::operator()() const /build/obj-x86_64-linux-gnu/../src/Common/ThreadPool.cpp:117:73 (clickhouse+0x8349ea8)
        ClickHouse#22 decltype(std::__1::forward<void>(fp)(std::__1::forward<void ThreadPoolImpl<std::__1::thread>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()>(fp0)...)) std::__1::__invoke<void ThreadPoolImpl<std::__1::thread>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()>(void&&, void ThreadPoolImpl<std::__1::thread>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()&&...) /build/obj-x86_64-linux-gnu/../contrib/libcxx/include/type_traits:3519:1 (clickhouse+0x8349ea8)
        ClickHouse#23 void std::__1::__thread_execute<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, void ThreadPoolImpl<std::__1::thread>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()>(std::__1::tuple<void, void ThreadPoolImpl<std::__1::thread>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()>&, std::__1::__tuple_indices<>) /build/obj-x86_64-linux-gnu/../contrib/libcxx/include/thread:273:5 (clickhouse+0x8349ea8)
        ClickHouse#24 void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, void ThreadPoolImpl<std::__1::thread>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()> >(void*) /build/obj-x86_64-linux-gnu/../contrib/libcxx/include/thread:284:5 (clickhouse+0x8349ea8)

      Previous read of size 1 at 0x7b50008c25c2 by thread T91:
        #0 DB::RemoteSource::generate() /build/obj-x86_64-linux-gnu/../src/Processors/Sources/RemoteSource.cpp:35:9 (clickhouse+0x11c1fb9e)
        ClickHouse#1 DB::ISource::work() /build/obj-x86_64-linux-gnu/../src/Processors/ISource.cpp:48:31 (clickhouse+0x11a6c852)
        ClickHouse#2 DB::SourceWithProgress::work() /build/obj-x86_64-linux-gnu/../src/Processors/Sources/SourceWithProgress.cpp:36:30 (clickhouse+0x11c26d1a)
        ClickHouse#3 DB::executeJob(DB::IProcessor*) /build/obj-x86_64-linux-gnu/../src/Processors/Executors/PipelineExecutor.cpp:78:20 (clickhouse+0x11ab4836)
        ClickHouse#4 DB::PipelineExecutor::addJob(DB::ExecutingGraph::Node*)::$_0::operator()() const /build/obj-x86_64-linux-gnu/../src/Processors/Executors/PipelineExecutor.cpp:95:13 (clickhouse+0x11ab4836)
        ClickHouse#5 decltype(std::__1::forward<DB::PipelineExecutor::addJob(DB::ExecutingGraph::Node*)::$_0&>(fp)()) std::__1::__invoke<DB::PipelineExecutor::addJob(DB::ExecutingGraph::Node*)::$_0&>(DB::PipelineExecutor::addJob(DB::ExecutingGraph::Node*)::$_0&) /build/obj-x86_64-linux-gnu/../contrib/libcxx/include/type_traits:3519:1 (clickhouse+0x11ab4836)
        ClickHouse#6 void std::__1::__invoke_void_return_wrapper<void>::__call<DB::PipelineExecutor::addJob(DB::ExecutingGraph::Node*)::$_0&>(DB::PipelineExecutor::addJob(DB::ExecutingGraph::Node*)::$_0&) /build/obj-x86_64-linux-gnu/../contrib/libcxx/include/__functional_base:348:9 (clickhouse+0x11ab4836)
        ClickHouse#7 std::__1::__function::__alloc_func<DB::PipelineExecutor::addJob(DB::ExecutingGraph::Node*)::$_0, std::__1::allocator<DB::PipelineExecutor::addJob(DB::ExecutingGraph::Node*)::$_0>, void ()>::operator()() /build/obj-x86_64-linux-gnu/../contrib/libcxx/include/functional:1540:16 (clickhouse+0x11ab4836)
        ClickHouse#8 std::__1::__function::__func<DB::PipelineExecutor::addJob(DB::ExecutingGraph::Node*)::$_0, std::__1::allocator<DB::PipelineExecutor::addJob(DB::ExecutingGraph::Node*)::$_0>, void ()>::operator()() /build/obj-x86_64-linux-gnu/../contrib/libcxx/include/functional:1714:12 (clickhouse+0x11ab4836)
        ClickHouse#9 std::__1::__function::__value_func<void ()>::operator()() const /build/obj-x86_64-linux-gnu/../contrib/libcxx/include/functional:1867:16 (clickhouse+0x11ab2801)
        ClickHouse#10 std::__1::function<void ()>::operator()() const /build/obj-x86_64-linux-gnu/../contrib/libcxx/include/functional:2473:12 (clickhouse+0x11ab2801)
        ClickHouse#11 DB::PipelineExecutor::executeStepImpl(unsigned long, unsigned long, std::__1::atomic<bool>*) /build/obj-x86_64-linux-gnu/../src/Processors/Executors/PipelineExecutor.cpp:561:17 (clickhouse+0x11ab2801)
        ClickHouse#12 DB::PipelineExecutor::executeSingleThread(unsigned long, unsigned long) /build/obj-x86_64-linux-gnu/../src/Processors/Executors/PipelineExecutor.cpp:477:5 (clickhouse+0x11ab538b)
        ClickHouse#13 DB::PipelineExecutor::executeImpl(unsigned long)::$_4::operator()() const /build/obj-x86_64-linux-gnu/../src/Processors/Executors/PipelineExecutor.cpp:736:21 (clickhouse+0x11ab538b)
        ClickHouse#14 decltype(std::__1::forward<DB::PipelineExecutor::executeImpl(unsigned long)::$_4&>(fp)()) std::__1::__invoke_constexpr<DB::PipelineExecutor::executeImpl(unsigned long)::$_4&>(DB::PipelineExecutor::executeImpl(unsigned long)::$_4&) /build/obj-x86_64-linux-gnu/../contrib/libcxx/include/type_traits:3525:1 (clickhouse+0x11ab538b)
        ClickHouse#15 decltype(auto) std::__1::__apply_tuple_impl<DB::PipelineExecutor::executeImpl(unsigned long)::$_4&, std::__1::tuple<>&>(DB::PipelineExecutor::executeImpl(unsigned long)::$_4&, std::__1::tuple<>&, std::__1::__tuple_indices<>) /build/obj-x86_64-linux-gnu/../contrib/libcxx/include/tuple:1415:1 (clickhouse+0x11ab538b)
        ClickHouse#16 decltype(auto) std::__1::apply<DB::PipelineExecutor::executeImpl(unsigned long)::$_4&, std::__1::tuple<>&>(DB::PipelineExecutor::executeImpl(unsigned long)::$_4&, std::__1::tuple<>&) /build/obj-x86_64-linux-gnu/../contrib/libcxx/include/tuple:1424:1 (clickhouse+0x11ab538b)
        ClickHouse#17 ThreadFromGlobalPool::ThreadFromGlobalPool<DB::PipelineExecutor::executeImpl(unsigned long)::$_4>(DB::PipelineExecutor::executeImpl(unsigned long)::$_4&&)::'lambda'()::operator()() /build/obj-x86_64-linux-gnu/../src/Common/ThreadPool.h:178:13 (clickhouse+0x11ab538b)
        ClickHouse#18 decltype(std::__1::forward<DB::PipelineExecutor::executeImpl(unsigned long)::$_4>(fp)()) std::__1::__invoke<ThreadFromGlobalPool::ThreadFromGlobalPool<DB::PipelineExecutor::executeImpl(unsigned long)::$_4>(DB::PipelineExecutor::executeImpl(unsigned long)::$_4&&)::'lambda'()&>(DB::PipelineExecutor::executeImpl(unsigned long)::$_4&&) /build/obj-x86_64-linux-gnu/../contrib/libcxx/include/type_traits:3519:1 (clickhouse+0x11ab538b)
        ClickHouse#19 void std::__1::__invoke_void_return_wrapper<void>::__call<ThreadFromGlobalPool::ThreadFromGlobalPool<DB::PipelineExecutor::executeImpl(unsigned long)::$_4>(DB::PipelineExecutor::executeImpl(unsigned long)::$_4&&)::'lambda'()&>(DB::PipelineExecutor::executeImpl(unsigned long)::$_4&&...) /build/obj-x86_64-linux-gnu/../contrib/libcxx/include/__functional_base:348:9 (clickhouse+0x11ab538b)
        ClickHouse#20 std::__1::__function::__alloc_func<ThreadFromGlobalPool::ThreadFromGlobalPool<DB::PipelineExecutor::executeImpl(unsigned long)::$_4>(DB::PipelineExecutor::executeImpl(unsigned long)::$_4&&)::'lambda'(), std::__1::allocator<ThreadFromGlobalPool::ThreadFromGlobalPool<DB::PipelineExecutor::executeImpl(unsigned long)::$_4>(DB::PipelineExecutor::executeImpl(unsigned long)::$_4&&)::'lambda'()>, void ()>::operator()() /build/obj-x86_64-linux-gnu/../contrib/libcxx/include/functional:1540:16 (clickhouse+0x11ab538b)
        ClickHouse#21 std::__1::__function::__func<ThreadFromGlobalPool::ThreadFromGlobalPool<DB::PipelineExecutor::executeImpl(unsigned long)::$_4>(DB::PipelineExecutor::executeImpl(unsigned long)::$_4&&)::'lambda'(), std::__1::allocator<ThreadFromGlobalPool::ThreadFromGlobalPool<DB::PipelineExecutor::executeImpl(unsigned long)::$_4>(DB::PipelineExecutor::executeImpl(unsigned long)::$_4&&)::'lambda'()>, void ()>::operator()() /build/obj-x86_64-linux-gnu/../contrib/libcxx/include/functional:1714:12 (clickhouse+0x11ab538b)
        ClickHouse#22 std::__1::__function::__value_func<void ()>::operator()() const /build/obj-x86_64-linux-gnu/../contrib/libcxx/include/functional:1867:16 (clickhouse+0x8346263)
        ClickHouse#23 std::__1::function<void ()>::operator()() const /build/obj-x86_64-linux-gnu/../contrib/libcxx/include/functional:2473:12 (clickhouse+0x8346263)
        ClickHouse#24 ThreadPoolImpl<std::__1::thread>::worker(std::__1::__list_iterator<std::__1::thread, void*>) /build/obj-x86_64-linux-gnu/../src/Common/ThreadPool.cpp:236:17 (clickhouse+0x8346263)
        ClickHouse#25 void ThreadPoolImpl<std::__1::thread>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()::operator()() const /build/obj-x86_64-linux-gnu/../src/Common/ThreadPool.cpp:117:73 (clickhouse+0x8349ea8)
        ClickHouse#26 decltype(std::__1::forward<void>(fp)(std::__1::forward<void ThreadPoolImpl<std::__1::thread>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()>(fp0)...)) std::__1::__invoke<void ThreadPoolImpl<std::__1::thread>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()>(void&&, void ThreadPoolImpl<std::__1::thread>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()&&...) /build/obj-x86_64-linux-gnu/../contrib/libcxx/include/type_traits:3519:1 (clickhouse+0x8349ea8)
        ClickHouse#27 void std::__1::__thread_execute<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, void ThreadPoolImpl<std::__1::thread>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()>(std::__1::tuple<void, void ThreadPoolImpl<std::__1::thread>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()>&, std::__1::__tuple_indices<>) /build/obj-x86_64-linux-gnu/../contrib/libcxx/include/thread:273:5 (clickhouse+0x8349ea8)
        ClickHouse#28 void* std::__1::__thread_proxy<std::__1::tuple<std::__1::unique_ptr<std::__1::__thread_struct, std::__1::default_delete<std::__1::__thread_struct> >, void ThreadPoolImpl<std::__1::thread>::scheduleImpl<void>(std::__1::function<void ()>, int, std::__1::optional<unsigned long>)::'lambda1'()> >(void*) /build/obj-x86_64-linux-gnu/../contrib/libcxx/include/thread:284:5 (clickhouse+0x8349ea8)
rschu1ze added a commit to rschu1ze/ClickHouse that referenced this pull request Apr 8, 2024
Fixes integration test_reload_certificate/test.py::test_first_than_second_cert

---

E           Exception: Sanitizer assert found for instance ==================
E           WARNING: ThreadSanitizer: data race (pid=1)
E             Write of size 8 at 0x7b2800025d30 by thread T2 (mutexes: write M0, write M1):
E               #0 free <null> (clickhouse+0x709a3e5) (BuildId: 706d92b17db171493f293d517643f726ee1b7b1e)
E               #1 CRYPTO_free build_docker/./contrib/openssl/crypto/mem.c:282:5 (clickhouse+0x2015f8ea) (BuildId: 706d92b17db171493f293d517643f726ee1b7b1e)
E               #2 EVP_PKEY_free build_docker/./contrib/openssl/crypto/evp/p_lib.c:1809:5 (clickhouse+0x2012a751) (BuildId: 706d92b17db171493f293d517643f726ee1b7b1e)
E               ClickHouse#3 Poco::Crypto::EVPPKey::~EVPPKey() build_docker/./base/poco/Crypto/src/EVPPKey.cpp:121:17 (clickhouse+0x1d00ffa9) (BuildId: 706d92b17db171493f293d517643f726ee1b7b1e)
E               ClickHouse#4 DB::CertificateReloader::Data::~Data() build_docker/./src/Server/CertificateReloader.h:71:12 (clickhouse+0x194fb42d) (BuildId: 706d92b17db171493f293d517643f726ee1b7b1e)
E               ClickHouse#5 std::__1::default_delete<DB::CertificateReloader::Data const>::operator()[abi:v15000](DB::CertificateReloader::Data const*) const build_docker/./contrib/llvm-project/libcxx/include/__memory/unique_ptr.h:48:5 (clickhouse+0x194fb42d)
E               ClickHouse#6 std::__1::__shared_ptr_pointer<DB::CertificateReloader::Data const*, std::__1::default_delete<DB::CertificateReloader::Data const>, std::__1::allocator<DB::CertificateReloader::Data const>>::__on_zero_shared() build_docker/./contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:263:5 (clickhouse+0x194fb42d)
E               ClickHouse#7 std::__1::__shared_count::__release_shared[abi:v15000]() build_docker/./contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:174:9 (clickhouse+0x194fade0) (BuildId: 706d92b17db171493f293d517643f726ee1b7b1e)
E               ClickHouse#8 std::__1::__shared_weak_count::__release_shared[abi:v15000]() build_docker/./contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:215:27 (clickhouse+0x194fade0)
E               ClickHouse#9 std::__1::shared_ptr<DB::CertificateReloader::Data const>::~shared_ptr[abi:v15000]() build_docker/./contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:702:23 (clickhouse+0x194fade0)
E               ClickHouse#10 std::__1::shared_ptr<DB::CertificateReloader::Data const>::operator=[abi:v15000](std::__1::shared_ptr<DB::CertificateReloader::Data const>&&) build_docker/./contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:723:9 (clickhouse+0x194fade0)
E               ClickHouse#11 MultiVersion<DB::CertificateReloader::Data>::set(std::__1::unique_ptr<DB::CertificateReloader::Data const, std::__1::default_delete<DB::CertificateReloader::Data const>>&&) build_docker/./src/Common/MultiVersion.h:76:25 (clickhouse+0x194fade0)
E               ClickHouse#12 DB::CertificateReloader::tryLoad(Poco::Util::AbstractConfiguration const&) build_docker/./src/Server/CertificateReloader.cpp:83:18 (clickhouse+0x194f94ca) (BuildId: 706d92b17db171493f293d517643f726ee1b7b1e)
E               ClickHouse#13 DB::Server::main(std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>>> const&)::$_6::operator()(Poco::AutoPtr<Poco::Util::AbstractConfiguration>, bool) const build_docker/./programs/server/Server.cpp:1546:45 (clickhouse+0xf384df7) (BuildId: 706d92b17db171493f293d517643f726ee1b7b1e)
E               ClickHouse#14 decltype(std::declval<DB::Server::main(std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>>> const&)::$_6&>()(std::declval<Poco::AutoPtr<Poco::Util::AbstractConfiguration>>(), std::declval<bool>())) std::__1::__invoke[abi:v15000]<DB::Server::main(std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>>> const&)::$_6&, Poco::AutoPtr<Poco::Util::AbstractConfiguration>, bool>(DB::Server::main(std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>>> const&)::$_6&, Poco::AutoPtr<Poco::Util::AbstractConfiguration>&&, bool&&) build_docker/./contrib/llvm-project/libcxx/include/__functional/invoke.h:394:23 (clickhouse+0xf3827a9) (BuildId: 706d92b17db171493f293d517643f726ee1b7b1e)
E               ClickHouse#15 void std::__1::__invoke_void_return_wrapper<void, true>::__call<DB::Server::main(std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>>> const&)::$_6&, Poco::AutoPtr<Poco::Util::AbstractConfiguration>, bool>(DB::Server::main(std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>>> const&)::$_6&, Poco::AutoPtr<Poco::Util::AbstractConfiguration>&&, bool&&) build_docker/./contrib/llvm-project/libcxx/include/__functional/invoke.h:479:9 (clickhouse+0xf3827a9)
E               ClickHouse#16 std::__1::__function::__default_alloc_func<DB::Server::main(std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>>> const&)::$_6, void (Poco::AutoPtr<Poco::Util::AbstractConfiguration>, bool)>::operator()[abi:v15000](Poco::AutoPtr<Poco::Util::AbstractConfiguration>&&, bool&&) build_docker/./contrib/llvm-project/libcxx/include/__functional/function.h:235:12 (clickhouse+0xf3827a9)
E               ClickHouse#17 void std::__1::__function::__policy_invoker<void (Poco::AutoPtr<Poco::Util::AbstractConfiguration>, bool)>::__call_impl<std::__1::__function::__default_alloc_func<DB::Server::main(std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>>> const&)::$_6, void (Poco::AutoPtr<Poco::Util::AbstractConfiguration>, bool)>>(std::__1::__function::__policy_storage const*, Poco::AutoPtr<Poco::Util::AbstractConfiguration>&&, bool) build_docker/./contrib/llvm-project/libcxx/include/__functional/function.h:716:16 (clickhouse+0xf3827a9)
E               ClickHouse#18 std::__1::__function::__policy_func<void (Poco::AutoPtr<Poco::Util::AbstractConfiguration>, bool)>::operator()[abi:v15000](Poco::AutoPtr<Poco::Util::AbstractConfiguration>&&, bool&&) const build_docker/./contrib/llvm-project/libcxx/include/__functional/function.h:848:16 (clickhouse+0x19fd2cbe) (BuildId: 706d92b17db171493f293d517643f726ee1b7b1e)
E               ClickHouse#19 std::__1::function<void (Poco::AutoPtr<Poco::Util::AbstractConfiguration>, bool)>::operator()(Poco::AutoPtr<Poco::Util::AbstractConfiguration>, bool) const build_docker/./contrib/llvm-project/libcxx/include/__functional/function.h:1187:12 (clickhouse+0x19fd2cbe)
E               ClickHouse#20 DB::ConfigReloader::reloadIfNewer(bool, bool, bool, bool) build_docker/./src/Common/Config/ConfigReloader.cpp:150:13 (clickhouse+0x19fd2cbe)
E               ClickHouse#21 DB::ConfigReloader::reload() build_docker/./src/Common/Config/ConfigReloader.h:51:21 (clickhouse+0xf38767c) (BuildId: 706d92b17db171493f293d517643f726ee1b7b1e)
E               ClickHouse#22 DB::Server::main(std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>>> const&)::$_13::operator()() const build_docker/./programs/server/Server.cpp:1731:31 (clickhouse+0xf38767c)
E               ClickHouse#23 decltype(std::declval<DB::Server::main(std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>>> const&)::$_13&>()()) std::__1::__invoke[abi:v15000]<DB::Server::main(std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>>> const&)::$_13&>(DB::Server::main(std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>>> const&)::$_13&) build_docker/./contrib/llvm-project/libcxx/include/__functional/invoke.h:394:23 (clickhouse+0xf38767c)
E               ClickHouse#24 void std::__1::__invoke_void_return_wrapper<void, true>::__call<DB::Server::main(std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>>> const&)::$_13&>(DB::Server::main(std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>>> const&)::$_13&) build_docker/./contrib/llvm-project/libcxx/include/__functional/invoke.h:479:9 (clickhouse+0xf38767c)
E               ClickHouse#25 std::__1::__function::__default_alloc_func<DB::Server::main(std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>>> const&)::$_13, void ()>::operator()[abi:v15000]() build_docker/./contrib/llvm-project/libcxx/include/__functional/function.h:235:12 (clickhouse+0xf38767c)
E               ClickHouse#26 void std::__1::__function::__policy_invoker<void ()>::__call_impl<std::__1::__function::__default_alloc_func<DB::Server::main(std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>>>> const&)::$_13, void ()>>(std::__1::__function::__policy_storage const*) build_docker/./contrib/llvm-project/libcxx/include/__functional/function.h:716:16 (clickhouse+0xf38767c)
E               ClickHouse#27 std::__1::__function::__policy_func<void ()>::operator()[abi:v15000]() const build_docker/./contrib/llvm-project/libcxx/include/__functional/function.h:848:16 (clickhouse+0x16907aa0) (BuildId: 706d92b17db171493f293d517643f726ee1b7b1e)
E               ClickHouse#28 std::__1::function<void ()>::operator()() const build_docker/./contrib/llvm-project/libcxx/include/__functional/function.h:1187:12 (clickhouse+0x16907aa0)
E               ClickHouse#29 DB::Context::reloadConfig() const build_docker/./src/Interpreters/Context.cpp:4357:5 (clickhouse+0x16907aa0)
E               ClickHouse#30 DB::InterpreterSystemQuery::execute() build_docker/./src/Interpreters/InterpreterSystemQuery.cpp:577:29 (clickhouse+0x17e78c19) (BuildId: 706d92b17db171493f293d517643f726ee1b7b1e)
E               ClickHouse#31 DB::executeQueryImpl(char const*, char const*, std::__1::shared_ptr<DB::Context>, DB::QueryFlags, DB::QueryProcessingStage::Enum, DB::ReadBuffer*) build_docker/./src/Interpreters/executeQuery.cpp:1195:40 (clickhouse+0x17e3e462) (BuildId: 706d92b17db171493f293d517643f726ee1b7b1e)
E               ClickHouse#32 DB::executeQuery(std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char>> const&, std::__1::shared_ptr<DB::Context>, DB::QueryFlags, DB::QueryProcessingStage::Enum) build_docker/./src/Interpreters/executeQuery.cpp:1374:26 (clickhouse+0x17e39837) (BuildId: 706d92b17db171493f293d517643f726ee1b7b1e)
E               ClickHouse#33 DB::TCPHandler::runImpl() build_docker/./src/Server/TCPHandler.cpp:518:54 (clickhouse+0x195cc651) (BuildId: 706d92b17db171493f293d517643f726ee1b7b1e)
E               ClickHouse#34 DB::TCPHandler::run() build_docker/./src/Server/TCPHandler.cpp:2329:9 (clickhouse+0x195e8707) (BuildId: 706d92b17db171493f293d517643f726ee1b7b1e)
E               ClickHouse#35 Poco::Net::TCPServerConnection::start() build_docker/./base/poco/Net/src/TCPServerConnection.cpp:43:3 (clickhouse+0x1d00d942) (BuildId: 706d92b17db171493f293d517643f726ee1b7b1e)
E               ClickHouse#36 Poco::Net::TCPServerDispatcher::run() build_docker/./base/poco/Net/src/TCPServerDispatcher.cpp:115:20 (clickhouse+0x1d00e1b1) (BuildId: 706d92b17db171493f293d517643f726ee1b7b1e)
E               ClickHouse#37 Poco::PooledThread::run() build_docker/./base/poco/Foundation/src/ThreadPool.cpp:188:14 (clickhouse+0x1d20f2e6) (BuildId: 706d92b17db171493f293d517643f726ee1b7b1e)
E               ClickHouse#38 Poco::(anonymous namespace)::RunnableHolder::run() build_docker/./base/poco/Foundation/src/Thread.cpp:45:11 (clickhouse+0x1d20d5af) (BuildId: 706d92b17db171493f293d517643f726ee1b7b1e)
E               ClickHouse#39 Poco::ThreadImpl::runnableEntry(void*) build_docker/./base/poco/Foundation/src/Thread_POSIX.cpp:335:27 (clickhouse+0x1d20ba69) (BuildId: 706d92b17db171493f293d517643f726ee1b7b1e)
E
E             Previous atomic write of size 4 at 0x7b2800025d30 by thread T3 (mutexes: write M2):
E               #0 CRYPTO_DOWN_REF build_docker/./contrib/openssl/include/internal/refcount.h:51:12 (clickhouse+0x2012a6e6) (BuildId: 706d92b17db171493f293d517643f726ee1b7b1e)
E               #1 EVP_PKEY_free build_docker/./contrib/openssl/crypto/evp/p_lib.c:1795:5 (clickhouse+0x2012a6e6)
E               #2 ssl_cert_clear_certs build_docker/./contrib/openssl/ssl/ssl_cert.c:246:9 (clickhouse+0x1ffafd37) (BuildId: 706d92b17db171493f293d517643f726ee1b7b1e)
E               ClickHouse#3 ssl_cert_free build_docker/./contrib/openssl/ssl/ssl_cert.c:277:5 (clickhouse+0x1ffafd37)
E               ClickHouse#4 ossl_ssl_connection_free build_docker/./contrib/openssl/ssl/ssl_lib.c:1458:5 (clickhouse+0x1ffba6af) (BuildId: 706d92b17db171493f293d517643f726ee1b7b1e)
E               ClickHouse#5 SSL_free build_docker/./contrib/openssl/ssl/ssl_lib.c:1417:9 (clickhouse+0x1ffb920e) (BuildId: 706d92b17db171493f293d517643f726ee1b7b1e)
E               ClickHouse#6 Poco::Net::SecureSocketImpl::reset() build_docker/./base/poco/NetSSL_OpenSSL/src/SecureSocketImpl.cpp:583:3 (clickhouse+0x1cfaac60) (BuildId: 706d92b17db171493f293d517643f726ee1b7b1e)
E               ClickHouse#7 Poco::Net::SecureSocketImpl::~SecureSocketImpl() build_docker/./base/poco/NetSSL_OpenSSL/src/SecureSocketImpl.cpp:80:3 (clickhouse+0x1cfaac60)
E               ClickHouse#8 Poco::Net::SecureStreamSocketImpl::~SecureStreamSocketImpl() build_docker/./base/poco/NetSSL_OpenSSL/src/SecureStreamSocketImpl.cpp:52:1 (clickhouse+0x1cfb15dd) (BuildId: 706d92b17db171493f293d517643f726ee1b7b1e)
E               ClickHouse#9 Poco::Net::SecureStreamSocketImpl::~SecureStreamSocketImpl() build_docker/./base/poco/NetSSL_OpenSSL/src/SecureStreamSocketImpl.cpp:43:1 (clickhouse+0x1cfb15dd)
E               ClickHouse#10 Poco::RefCountedObject::release() const build_docker/./base/poco/Foundation/include/Poco/RefCountedObject.h:86:13 (clickhouse+0x1cffc81e) (BuildId: 706d92b17db171493f293d517643f726ee1b7b1e)
E               ClickHouse#11 Poco::Net::Socket::~Socket() build_docker/./base/poco/Net/src/Socket.cpp:68:10 (clickhouse+0x1cffc81e)
E               ClickHouse#12 Poco::Net::StreamSocket::~StreamSocket() build_docker/./base/poco/Net/src/StreamSocket.cpp:63:1 (clickhouse+0x1d009c39) (BuildId: 706d92b17db171493f293d517643f726ee1b7b1e)
E               ClickHouse#13 Poco::Net::TCPConnectionNotification::~TCPConnectionNotification() build_docker/./base/poco/Net/src/TCPServerDispatcher.cpp:43:2 (clickhouse+0x1d00ef50) (BuildId: 706d92b17db171493f293d517643f726ee1b7b1e)
E               ClickHouse#14 Poco::Net::TCPConnectionNotification::~TCPConnectionNotification() build_docker/./base/poco/Net/src/TCPServerDispatcher.cpp:42:2 (clickhouse+0x1d00ef50)
E               ClickHouse#15 Poco::RefCountedObject::release() const build_docker/./base/poco/Foundation/include/Poco/RefCountedObject.h:86:13 (clickhouse+0x1d00e203) (BuildId: 706d92b17db171493f293d517643f726ee1b7b1e)
E               ClickHouse#16 Poco::AutoPtr<Poco::Notification>::~AutoPtr() build_docker/./base/poco/Foundation/include/Poco/AutoPtr.h:91:19 (clickhouse+0x1d00e203)
E               ClickHouse#17 Poco::Net::TCPServerDispatcher::run() build_docker/./base/poco/Net/src/TCPServerDispatcher.cpp:122:3 (clickhouse+0x1d00e203)
E               ClickHouse#18 Poco::PooledThread::run() build_docker/./base/poco/Foundation/src/ThreadPool.cpp:188:14 (clickhouse+0x1d20f2e6) (BuildId: 706d92b17db171493f293d517643f726ee1b7b1e)
E               ClickHouse#19 Poco::(anonymous namespace)::RunnableHolder::run() build_docker/./base/poco/Foundation/src/Thread.cpp:45:11 (clickhouse+0x1d20d5af) (BuildId: 706d92b17db171493f293d517643f726ee1b7b1e)
E               ClickHouse#20 Poco::ThreadImpl::runnableEntry(void*) build_docker/./base/poco/Foundation/src/Thread_POSIX.cpp:335:27 (clickhouse+0x1d20ba69) (BuildId: 706d92b17db171493f293d517643f726ee1b7b1e)
E
azat added a commit to azat/ClickHouse that referenced this pull request Jul 16, 2025
…ionary cleanup

<details>

<summary>stacktrace</summary>

    ClickHouse#5  DB::ContextSharedMutex::lockSharedImpl (this=this@entry=0x7ffff5b96040) at /src/ch/clickhouse/src/Interpreters/Context.cpp:1036
            watch = {start_ns = 98678735300141, stop_ns = 0, clock_type = 4, is_running = true}
            increment = {what = <optimized out>, amount = 1}
    ClickHouse#6  0x00005555699352d6 in DB::SharedMutexHelper<DB::ContextSharedMutex, DB::SharedMutex>::lock_shared (this=0x7ffff5b96040) at /src/ch/clickhouse/src/Common/SharedMutexHelper.h:70
    ClickHouse#7  DB::SharedLockGuard<DB::ContextSharedMutex>::SharedLockGuard (mutex_=..., this=<optimized out>) at /src/ch/clickhouse/src/Common/SharedLockGuard.h:19
    ClickHouse#8  DB::ContextSharedPart::getConfigRef (this=0x7ffff5b96000) at /src/ch/clickhouse/src/Interpreters/Context.cpp:760
    ClickHouse#9  DB::Context::getConfigRef (this=<optimized out>) at /src/ch/clickhouse/src/Interpreters/Context.cpp:1590
    ClickHouse#10 0x000055556450941c in DB::ProxyConfigurationResolverProvider::get (request_protocol=DB::ProxyConfiguration::Protocol::HTTP) at /src/ch/clickhouse/src/Common/ProxyConfigurationResolverProvider.cpp:161
    ClickHouse#11 0x00005555669ea75f in DB::BuilderRWBufferFromHTTP::create (this=0x7fffffffa848, credentials_=...) at /src/ch/clickhouse/src/IO/ReadWriteBufferFromHTTP.cpp:814
    ClickHouse#12 0x000055556cea0035 in DB::ExternalDictionaryLibraryBridgeHelper::bridgeHandShake (this=0x7ffd60c4ca18) at /src/ch/clickhouse/src/BridgeHelper/ExternalDictionaryLibraryBridgeHelper.cpp:79
    ClickHouse#13 0x000055556cea1f34 in DB::ExternalDictionaryLibraryBridgeHelper::removeLibrary (this=0x7ffff5b96044) at /src/ch/clickhouse/src/BridgeHelper/ExternalDictionaryLibraryBridgeHelper.cpp:186
    ClickHouse#14 0x0000555566cb0248 in DB::LibraryDictionarySource::~LibraryDictionarySource (this=0x7ffd60c78318) at /src/ch/clickhouse/src/Dictionaries/LibraryDictionarySource.cpp:70
    ClickHouse#15 0x000055556708d775 in std::__1::__shared_count::__release_shared[abi:ne190107]() (this=0x7ffd60c78300) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:156
    ClickHouse#16 std::__1::__shared_weak_count::__release_shared[abi:ne190107]() (this=0x7ffd60c78300) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:185
    ClickHouse#17 std::__1::shared_ptr<DB::IDictionarySource>::~shared_ptr[abi:ne190107]() (this=0x7ffd60c605b0) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:668
    ClickHouse#18 DB::HashedDictionary<(DB::DictionaryKeyType)0, false, false>::~HashedDictionary (this=0x7ffd60c60398) at /src/ch/clickhouse/src/Dictionaries/HashedDictionary.h:378
    ClickHouse#19 0x0000555569a9c477 in std::__1::__shared_count::__release_shared[abi:ne190107]() (this=0x7ffd60c60380) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:156
    ClickHouse#20 std::__1::__shared_weak_count::__release_shared[abi:ne190107]() (this=0x7ffd60c60380) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:185
    ClickHouse#21 std::__1::shared_ptr<DB::IExternalLoadable>::~shared_ptr[abi:ne190107]() (this=0x7ffff4832560) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:668
    ClickHouse#22 DB::ExternalLoader::LoadingDispatcher::Info::~Info (this=0x7ffff4832548) at /src/ch/clickhouse/src/Interpreters/ExternalLoader.cpp:719
    ClickHouse#23 std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const, DB::ExternalLoader::LoadingDispatcher::Info>::~pair (this=0x7ffff4832530, this@entry=0x7ffd60c60390) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__utility/pair.h:65
    ClickHouse#24 __destroy_at<std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const, DB::ExternalLoader::LoadingDispatcher::Info>, 0> (__loc=__loc@entry=0x7ffff4832530) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/construct_at.h:67
    ClickHouse#25 0x0000555569a9c628 in destroy<std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const, DB::ExternalLoader::LoadingDispatcher::Info>, void, 0> (__p=0x7ffff5b96044, __p@entry=0x7ffff4832530) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/allocator_traits.h:339
    ClickHouse#28 std::__1::unique_ptr<std::__1::__hash_node<std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, DB::ExternalLoader::LoadingDispatcher::Info>, void*>, std::__1::__hash_node_destructor<std::__1::allocator<std::__1::__hash_node<std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, DB::ExternalLoader::LoadingDispatcher::Info>, void*> > > >::~unique_ptr[abi:ne190107]() (this=<optimized out>) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/unique_ptr.h:261
    ClickHouse#31 DB::ExternalLoader::LoadingDispatcher::setConfiguration (this=this@entry=0x7ffecad4c300, new_configs=...) at /src/ch/clickhouse/src/Interpreters/ExternalLoader.cpp:495
    ClickHouse#32 0x0000555569a9116d in DB::ExternalLoader::reloadConfig (this=0x7ffecb3fd740, repository_name=...) at /src/ch/clickhouse/src/Interpreters/ExternalLoader.cpp:1533
    ClickHouse#33 DB::ExternalLoader::addConfigRepository(std::__1::unique_ptr<DB::IExternalLoaderConfigRepository, std::__1::default_delete<DB::IExternalLoaderConfigRepository> >) const::$_0::operator()() const (this=<optimized out>) at /src/ch/clickhouse/src/Interpreters/ExternalLoader.cpp:1334
    ClickHouse#34 std::__1::__invoke[abi:ne190107]<DB::ExternalLoader::addConfigRepository(std::__1::unique_ptr<DB::IExternalLoaderConfigRepository, std::__1::default_delete<DB::IExternalLoaderConfigRepository> >) const::$_0&>(DB::ExternalLoader::addConfigRepository(std::__1::unique_ptr<DB::IExternalLoaderConfigRepository, std::__1::default_delete<DB::IExternalLoaderConfigRepository> >) const::$_0&) (__f=...) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__type_traits/invoke.h:149
    ClickHouse#35 std::__1::__invoke_void_return_wrapper<void, true>::__call[abi:ne190107]<DB::ExternalLoader::addConfigRepository(std::__1::unique_ptr<DB::IExternalLoaderConfigRepository, std::__1::default_delete<DB::IExternalLoaderConfigRepository> >) const::$_0&>(DB::ExternalLoader::addConfigRepository(std::__1::unique_ptr<DB::IExternalLoaderConfigRepository, std::__1::default_delete<DB::IExternalLoaderConfigRepository> >) const::$_0&) (__args=...) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__type_traits/invoke.h:224
    ClickHouse#36 std::__1::__function::__default_alloc_func<DB::ExternalLoader::addConfigRepository(std::__1::unique_ptr<DB::IExternalLoaderConfigRepository, std::__1::default_delete<DB::IExternalLoaderConfigRepository> >) const::$_0, void ()>::operator()[abi:ne190107]() (this=<optimized out>) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__functional/function.h:210
    ClickHouse#37 std::__1::__function::__policy_invoker<void ()>::__call_impl[abi:ne190107]<std::__1::__function::__default_alloc_func<DB::ExternalLoader::addConfigRepository(std::__1::unique_ptr<DB::IExternalLoaderConfigRepository, std::__1::default_delete<DB::IExternalLoaderConfigRepository> >) const::$_0, void ()> ClickHouse#38 0x0000555569966aaa in std::__1::__function::__policy_func<void ()>::operator()[abi:ne190107]() const (this=0x7ffff5b96044) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__functional/function.h:716
    ClickHouse#39 std::__1::function<void()>::operator() (this=0x7ffff5b96044) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__functional/function.h:989
    ClickHouse#40 BasicScopeGuard<std::__1::function<void()> >::invoke (this=0x7ffff5b96044) at /src/ch/clickhouse/base/base/../base/scope_guard.h:101
    ClickHouse#41 BasicScopeGuard<std::__1::function<void()> >::reset (this=0x7ffff5b96044) at /src/ch/clickhouse/base/base/../base/scope_guard.h:63
    ClickHouse#42 DB::ContextSharedPart::shutdown (this=0x7ffff5b96000) at /src/ch/clickhouse/src/Interpreters/Context.cpp:909
    ClickHouse#43 0x00005555644cf5cb in DB::Server::main(std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&)::$_3::operator()() const (this=this@entry=0x7fffffffc870) at /src/ch/clickhouse/programs/server/Server.cpp:1257
    ClickHouse#44 0x00005555644b4439 in BasicScopeGuard<DB::Server::main(std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&)::$_3>::invoke (this=0x7fffffffc870) at /src/ch/clickhouse/base/base/../base/scope_guard.h:101
    ClickHouse#45 BasicScopeGuard<DB::Server::main(std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&)::$_3>::~BasicScopeGuard (this=0x7fffffffc870) at /src/ch/clickhouse/base/base/../base/scope_guard.h:50
    ClickHouse#46 DB::Server::main (this=0x7fffffffe4c8) at /src/ch/clickhouse/programs/server/Server.cpp:2788
    ClickHouse#47 0x0000555572cbbee9 in Poco::Util::Application::run (this=0x7fffffffe4c8) at /src/ch/clickhouse/base/poco/Util/src/Application.cpp:315
    ClickHouse#48 0x000055556449c390 in DB::Server::run (this=0x7fffffffe4c8) at /src/ch/clickhouse/programs/server/Server.cpp:610
    ClickHouse#49 0x0000555564499aec in mainEntryClickHouseServer (argc=6, argv=0x7ffff67ecdc0) at /src/ch/clickhouse/programs/server/Server.cpp:397
    ClickHouse#50 0x000055555dc994c2 in main (argc_=<optimized out>, argv_=<optimized out>) at /src/ch/clickhouse/programs/main.cpp:340

</details>
azat added a commit to azat/ClickHouse that referenced this pull request Jul 16, 2025
…ary bridge cleanup

<details>

<summary>stacktrace</summary>

    ClickHouse#5  DB::ContextSharedMutex::lockSharedImpl (this=this@entry=0x7ffff5b96040) at /src/ch/clickhouse/src/Interpreters/Context.cpp:1036
            watch = {start_ns = 98678735300141, stop_ns = 0, clock_type = 4, is_running = true}
            increment = {what = <optimized out>, amount = 1}
    ClickHouse#6  0x00005555699352d6 in DB::SharedMutexHelper<DB::ContextSharedMutex, DB::SharedMutex>::lock_shared (this=0x7ffff5b96040) at /src/ch/clickhouse/src/Common/SharedMutexHelper.h:70
    ClickHouse#7  DB::SharedLockGuard<DB::ContextSharedMutex>::SharedLockGuard (mutex_=..., this=<optimized out>) at /src/ch/clickhouse/src/Common/SharedLockGuard.h:19
    ClickHouse#8  DB::ContextSharedPart::getConfigRef (this=0x7ffff5b96000) at /src/ch/clickhouse/src/Interpreters/Context.cpp:760
    ClickHouse#9  DB::Context::getConfigRef (this=<optimized out>) at /src/ch/clickhouse/src/Interpreters/Context.cpp:1590
    ClickHouse#10 0x000055556450941c in DB::ProxyConfigurationResolverProvider::get (request_protocol=DB::ProxyConfiguration::Protocol::HTTP) at /src/ch/clickhouse/src/Common/ProxyConfigurationResolverProvider.cpp:161
    ClickHouse#11 0x00005555669ea75f in DB::BuilderRWBufferFromHTTP::create (this=0x7fffffffa848, credentials_=...) at /src/ch/clickhouse/src/IO/ReadWriteBufferFromHTTP.cpp:814
    ClickHouse#12 0x000055556cea0035 in DB::ExternalDictionaryLibraryBridgeHelper::bridgeHandShake (this=0x7ffd60c4ca18) at /src/ch/clickhouse/src/BridgeHelper/ExternalDictionaryLibraryBridgeHelper.cpp:79
    ClickHouse#13 0x000055556cea1f34 in DB::ExternalDictionaryLibraryBridgeHelper::removeLibrary (this=0x7ffff5b96044) at /src/ch/clickhouse/src/BridgeHelper/ExternalDictionaryLibraryBridgeHelper.cpp:186
    ClickHouse#14 0x0000555566cb0248 in DB::LibraryDictionarySource::~LibraryDictionarySource (this=0x7ffd60c78318) at /src/ch/clickhouse/src/Dictionaries/LibraryDictionarySource.cpp:70
    ClickHouse#15 0x000055556708d775 in std::__1::__shared_count::__release_shared[abi:ne190107]() (this=0x7ffd60c78300) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:156
    ClickHouse#16 std::__1::__shared_weak_count::__release_shared[abi:ne190107]() (this=0x7ffd60c78300) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:185
    ClickHouse#17 std::__1::shared_ptr<DB::IDictionarySource>::~shared_ptr[abi:ne190107]() (this=0x7ffd60c605b0) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:668
    ClickHouse#18 DB::HashedDictionary<(DB::DictionaryKeyType)0, false, false>::~HashedDictionary (this=0x7ffd60c60398) at /src/ch/clickhouse/src/Dictionaries/HashedDictionary.h:378
    ClickHouse#19 0x0000555569a9c477 in std::__1::__shared_count::__release_shared[abi:ne190107]() (this=0x7ffd60c60380) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:156
    ClickHouse#20 std::__1::__shared_weak_count::__release_shared[abi:ne190107]() (this=0x7ffd60c60380) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:185
    ClickHouse#21 std::__1::shared_ptr<DB::IExternalLoadable>::~shared_ptr[abi:ne190107]() (this=0x7ffff4832560) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:668
    ClickHouse#22 DB::ExternalLoader::LoadingDispatcher::Info::~Info (this=0x7ffff4832548) at /src/ch/clickhouse/src/Interpreters/ExternalLoader.cpp:719
    ClickHouse#23 std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const, DB::ExternalLoader::LoadingDispatcher::Info>::~pair (this=0x7ffff4832530, this@entry=0x7ffd60c60390) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__utility/pair.h:65
    ClickHouse#24 __destroy_at<std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const, DB::ExternalLoader::LoadingDispatcher::Info>, 0> (__loc=__loc@entry=0x7ffff4832530) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/construct_at.h:67
    ClickHouse#25 0x0000555569a9c628 in destroy<std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const, DB::ExternalLoader::LoadingDispatcher::Info>, void, 0> (__p=0x7ffff5b96044, __p@entry=0x7ffff4832530) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/allocator_traits.h:339
    ClickHouse#28 std::__1::unique_ptr<std::__1::__hash_node<std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, DB::ExternalLoader::LoadingDispatcher::Info>, void*>, std::__1::__hash_node_destructor<std::__1::allocator<std::__1::__hash_node<std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, DB::ExternalLoader::LoadingDispatcher::Info>, void*> > > >::~unique_ptr[abi:ne190107]() (this=<optimized out>) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/unique_ptr.h:261
    ClickHouse#31 DB::ExternalLoader::LoadingDispatcher::setConfiguration (this=this@entry=0x7ffecad4c300, new_configs=...) at /src/ch/clickhouse/src/Interpreters/ExternalLoader.cpp:495
    ClickHouse#32 0x0000555569a9116d in DB::ExternalLoader::reloadConfig (this=0x7ffecb3fd740, repository_name=...) at /src/ch/clickhouse/src/Interpreters/ExternalLoader.cpp:1533
    ClickHouse#33 DB::ExternalLoader::addConfigRepository(std::__1::unique_ptr<DB::IExternalLoaderConfigRepository, std::__1::default_delete<DB::IExternalLoaderConfigRepository> >) const::$_0::operator()() const (this=<optimized out>) at /src/ch/clickhouse/src/Interpreters/ExternalLoader.cpp:1334
    ClickHouse#34 std::__1::__invoke[abi:ne190107]<DB::ExternalLoader::addConfigRepository(std::__1::unique_ptr<DB::IExternalLoaderConfigRepository, std::__1::default_delete<DB::IExternalLoaderConfigRepository> >) const::$_0&>(DB::ExternalLoader::addConfigRepository(std::__1::unique_ptr<DB::IExternalLoaderConfigRepository, std::__1::default_delete<DB::IExternalLoaderConfigRepository> >) const::$_0&) (__f=...) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__type_traits/invoke.h:149
    ClickHouse#35 std::__1::__invoke_void_return_wrapper<void, true>::__call[abi:ne190107]<DB::ExternalLoader::addConfigRepository(std::__1::unique_ptr<DB::IExternalLoaderConfigRepository, std::__1::default_delete<DB::IExternalLoaderConfigRepository> >) const::$_0&>(DB::ExternalLoader::addConfigRepository(std::__1::unique_ptr<DB::IExternalLoaderConfigRepository, std::__1::default_delete<DB::IExternalLoaderConfigRepository> >) const::$_0&) (__args=...) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__type_traits/invoke.h:224
    ClickHouse#36 std::__1::__function::__default_alloc_func<DB::ExternalLoader::addConfigRepository(std::__1::unique_ptr<DB::IExternalLoaderConfigRepository, std::__1::default_delete<DB::IExternalLoaderConfigRepository> >) const::$_0, void ()>::operator()[abi:ne190107]() (this=<optimized out>) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__functional/function.h:210
    ClickHouse#37 std::__1::__function::__policy_invoker<void ()>::__call_impl[abi:ne190107]<std::__1::__function::__default_alloc_func<DB::ExternalLoader::addConfigRepository(std::__1::unique_ptr<DB::IExternalLoaderConfigRepository, std::__1::default_delete<DB::IExternalLoaderConfigRepository> >) const::$_0, void ()> ClickHouse#38 0x0000555569966aaa in std::__1::__function::__policy_func<void ()>::operator()[abi:ne190107]() const (this=0x7ffff5b96044) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__functional/function.h:716
    ClickHouse#39 std::__1::function<void()>::operator() (this=0x7ffff5b96044) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__functional/function.h:989
    ClickHouse#40 BasicScopeGuard<std::__1::function<void()> >::invoke (this=0x7ffff5b96044) at /src/ch/clickhouse/base/base/../base/scope_guard.h:101
    ClickHouse#41 BasicScopeGuard<std::__1::function<void()> >::reset (this=0x7ffff5b96044) at /src/ch/clickhouse/base/base/../base/scope_guard.h:63
    ClickHouse#42 DB::ContextSharedPart::shutdown (this=0x7ffff5b96000) at /src/ch/clickhouse/src/Interpreters/Context.cpp:909
    ClickHouse#43 0x00005555644cf5cb in DB::Server::main(std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&)::$_3::operator()() const (this=this@entry=0x7fffffffc870) at /src/ch/clickhouse/programs/server/Server.cpp:1257
    ClickHouse#44 0x00005555644b4439 in BasicScopeGuard<DB::Server::main(std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&)::$_3>::invoke (this=0x7fffffffc870) at /src/ch/clickhouse/base/base/../base/scope_guard.h:101
    ClickHouse#45 BasicScopeGuard<DB::Server::main(std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&)::$_3>::~BasicScopeGuard (this=0x7fffffffc870) at /src/ch/clickhouse/base/base/../base/scope_guard.h:50
    ClickHouse#46 DB::Server::main (this=0x7fffffffe4c8) at /src/ch/clickhouse/programs/server/Server.cpp:2788
    ClickHouse#47 0x0000555572cbbee9 in Poco::Util::Application::run (this=0x7fffffffe4c8) at /src/ch/clickhouse/base/poco/Util/src/Application.cpp:315
    ClickHouse#48 0x000055556449c390 in DB::Server::run (this=0x7fffffffe4c8) at /src/ch/clickhouse/programs/server/Server.cpp:610
    ClickHouse#49 0x0000555564499aec in mainEntryClickHouseServer (argc=6, argv=0x7ffff67ecdc0) at /src/ch/clickhouse/programs/server/Server.cpp:397
    ClickHouse#50 0x000055555dc994c2 in main (argc_=<optimized out>, argv_=<optimized out>) at /src/ch/clickhouse/programs/main.cpp:340

</details>
azat added a commit to azat/ClickHouse that referenced this pull request Jul 16, 2025
…ary bridge cleanup

<details>

<summary>stacktrace</summary>

    ClickHouse#5  DB::ContextSharedMutex::lockSharedImpl (this=this@entry=0x7ffff5b96040) at /src/ch/clickhouse/src/Interpreters/Context.cpp:1036
            watch = {start_ns = 98678735300141, stop_ns = 0, clock_type = 4, is_running = true}
            increment = {what = <optimized out>, amount = 1}
    ClickHouse#6  0x00005555699352d6 in DB::SharedMutexHelper<DB::ContextSharedMutex, DB::SharedMutex>::lock_shared (this=0x7ffff5b96040) at /src/ch/clickhouse/src/Common/SharedMutexHelper.h:70
    ClickHouse#7  DB::SharedLockGuard<DB::ContextSharedMutex>::SharedLockGuard (mutex_=..., this=<optimized out>) at /src/ch/clickhouse/src/Common/SharedLockGuard.h:19
    ClickHouse#8  DB::ContextSharedPart::getConfigRef (this=0x7ffff5b96000) at /src/ch/clickhouse/src/Interpreters/Context.cpp:760
    ClickHouse#9  DB::Context::getConfigRef (this=<optimized out>) at /src/ch/clickhouse/src/Interpreters/Context.cpp:1590
    ClickHouse#10 0x000055556450941c in DB::ProxyConfigurationResolverProvider::get (request_protocol=DB::ProxyConfiguration::Protocol::HTTP) at /src/ch/clickhouse/src/Common/ProxyConfigurationResolverProvider.cpp:161
    ClickHouse#11 0x00005555669ea75f in DB::BuilderRWBufferFromHTTP::create (this=0x7fffffffa848, credentials_=...) at /src/ch/clickhouse/src/IO/ReadWriteBufferFromHTTP.cpp:814
    ClickHouse#12 0x000055556cea0035 in DB::ExternalDictionaryLibraryBridgeHelper::bridgeHandShake (this=0x7ffd60c4ca18) at /src/ch/clickhouse/src/BridgeHelper/ExternalDictionaryLibraryBridgeHelper.cpp:79
    ClickHouse#13 0x000055556cea1f34 in DB::ExternalDictionaryLibraryBridgeHelper::removeLibrary (this=0x7ffff5b96044) at /src/ch/clickhouse/src/BridgeHelper/ExternalDictionaryLibraryBridgeHelper.cpp:186
    ClickHouse#14 0x0000555566cb0248 in DB::LibraryDictionarySource::~LibraryDictionarySource (this=0x7ffd60c78318) at /src/ch/clickhouse/src/Dictionaries/LibraryDictionarySource.cpp:70
    ClickHouse#15 0x000055556708d775 in std::__1::__shared_count::__release_shared[abi:ne190107]() (this=0x7ffd60c78300) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:156
    ClickHouse#16 std::__1::__shared_weak_count::__release_shared[abi:ne190107]() (this=0x7ffd60c78300) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:185
    ClickHouse#17 std::__1::shared_ptr<DB::IDictionarySource>::~shared_ptr[abi:ne190107]() (this=0x7ffd60c605b0) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:668
    ClickHouse#18 DB::HashedDictionary<(DB::DictionaryKeyType)0, false, false>::~HashedDictionary (this=0x7ffd60c60398) at /src/ch/clickhouse/src/Dictionaries/HashedDictionary.h:378
    ClickHouse#19 0x0000555569a9c477 in std::__1::__shared_count::__release_shared[abi:ne190107]() (this=0x7ffd60c60380) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:156
    ClickHouse#20 std::__1::__shared_weak_count::__release_shared[abi:ne190107]() (this=0x7ffd60c60380) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:185
    ClickHouse#21 std::__1::shared_ptr<DB::IExternalLoadable>::~shared_ptr[abi:ne190107]() (this=0x7ffff4832560) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:668
    ClickHouse#22 DB::ExternalLoader::LoadingDispatcher::Info::~Info (this=0x7ffff4832548) at /src/ch/clickhouse/src/Interpreters/ExternalLoader.cpp:719
    ClickHouse#23 std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const, DB::ExternalLoader::LoadingDispatcher::Info>::~pair (this=0x7ffff4832530, this@entry=0x7ffd60c60390) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__utility/pair.h:65
    ClickHouse#24 __destroy_at<std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const, DB::ExternalLoader::LoadingDispatcher::Info>, 0> (__loc=__loc@entry=0x7ffff4832530) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/construct_at.h:67
    ClickHouse#25 0x0000555569a9c628 in destroy<std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const, DB::ExternalLoader::LoadingDispatcher::Info>, void, 0> (__p=0x7ffff5b96044, __p@entry=0x7ffff4832530) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/allocator_traits.h:339
    ClickHouse#28 std::__1::unique_ptr<std::__1::__hash_node<std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, DB::ExternalLoader::LoadingDispatcher::Info>, void*>, std::__1::__hash_node_destructor<std::__1::allocator<std::__1::__hash_node<std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, DB::ExternalLoader::LoadingDispatcher::Info>, void*> > > >::~unique_ptr[abi:ne190107]() (this=<optimized out>) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/unique_ptr.h:261
    ClickHouse#31 DB::ExternalLoader::LoadingDispatcher::setConfiguration (this=this@entry=0x7ffecad4c300, new_configs=...) at /src/ch/clickhouse/src/Interpreters/ExternalLoader.cpp:495
    ClickHouse#32 0x0000555569a9116d in DB::ExternalLoader::reloadConfig (this=0x7ffecb3fd740, repository_name=...) at /src/ch/clickhouse/src/Interpreters/ExternalLoader.cpp:1533
    ClickHouse#33 DB::ExternalLoader::addConfigRepository(std::__1::unique_ptr<DB::IExternalLoaderConfigRepository, std::__1::default_delete<DB::IExternalLoaderConfigRepository> >) const::$_0::operator()() const (this=<optimized out>) at /src/ch/clickhouse/src/Interpreters/ExternalLoader.cpp:1334
    ClickHouse#34 std::__1::__invoke[abi:ne190107]<DB::ExternalLoader::addConfigRepository(std::__1::unique_ptr<DB::IExternalLoaderConfigRepository, std::__1::default_delete<DB::IExternalLoaderConfigRepository> >) const::$_0&>(DB::ExternalLoader::addConfigRepository(std::__1::unique_ptr<DB::IExternalLoaderConfigRepository, std::__1::default_delete<DB::IExternalLoaderConfigRepository> >) const::$_0&) (__f=...) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__type_traits/invoke.h:149
    ClickHouse#35 std::__1::__invoke_void_return_wrapper<void, true>::__call[abi:ne190107]<DB::ExternalLoader::addConfigRepository(std::__1::unique_ptr<DB::IExternalLoaderConfigRepository, std::__1::default_delete<DB::IExternalLoaderConfigRepository> >) const::$_0&>(DB::ExternalLoader::addConfigRepository(std::__1::unique_ptr<DB::IExternalLoaderConfigRepository, std::__1::default_delete<DB::IExternalLoaderConfigRepository> >) const::$_0&) (__args=...) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__type_traits/invoke.h:224
    ClickHouse#36 std::__1::__function::__default_alloc_func<DB::ExternalLoader::addConfigRepository(std::__1::unique_ptr<DB::IExternalLoaderConfigRepository, std::__1::default_delete<DB::IExternalLoaderConfigRepository> >) const::$_0, void ()>::operator()[abi:ne190107]() (this=<optimized out>) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__functional/function.h:210
    ClickHouse#37 std::__1::__function::__policy_invoker<void ()>::__call_impl[abi:ne190107]<std::__1::__function::__default_alloc_func<DB::ExternalLoader::addConfigRepository(std::__1::unique_ptr<DB::IExternalLoaderConfigRepository, std::__1::default_delete<DB::IExternalLoaderConfigRepository> >) const::$_0, void ()> ClickHouse#38 0x0000555569966aaa in std::__1::__function::__policy_func<void ()>::operator()[abi:ne190107]() const (this=0x7ffff5b96044) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__functional/function.h:716
    ClickHouse#39 std::__1::function<void()>::operator() (this=0x7ffff5b96044) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__functional/function.h:989
    ClickHouse#40 BasicScopeGuard<std::__1::function<void()> >::invoke (this=0x7ffff5b96044) at /src/ch/clickhouse/base/base/../base/scope_guard.h:101
    ClickHouse#41 BasicScopeGuard<std::__1::function<void()> >::reset (this=0x7ffff5b96044) at /src/ch/clickhouse/base/base/../base/scope_guard.h:63
    ClickHouse#42 DB::ContextSharedPart::shutdown (this=0x7ffff5b96000) at /src/ch/clickhouse/src/Interpreters/Context.cpp:909
    ClickHouse#43 0x00005555644cf5cb in DB::Server::main(std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&)::$_3::operator()() const (this=this@entry=0x7fffffffc870) at /src/ch/clickhouse/programs/server/Server.cpp:1257
    ClickHouse#44 0x00005555644b4439 in BasicScopeGuard<DB::Server::main(std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&)::$_3>::invoke (this=0x7fffffffc870) at /src/ch/clickhouse/base/base/../base/scope_guard.h:101
    ClickHouse#45 BasicScopeGuard<DB::Server::main(std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&)::$_3>::~BasicScopeGuard (this=0x7fffffffc870) at /src/ch/clickhouse/base/base/../base/scope_guard.h:50
    ClickHouse#46 DB::Server::main (this=0x7fffffffe4c8) at /src/ch/clickhouse/programs/server/Server.cpp:2788
    ClickHouse#47 0x0000555572cbbee9 in Poco::Util::Application::run (this=0x7fffffffe4c8) at /src/ch/clickhouse/base/poco/Util/src/Application.cpp:315
    ClickHouse#48 0x000055556449c390 in DB::Server::run (this=0x7fffffffe4c8) at /src/ch/clickhouse/programs/server/Server.cpp:610
    ClickHouse#49 0x0000555564499aec in mainEntryClickHouseServer (argc=6, argv=0x7ffff67ecdc0) at /src/ch/clickhouse/programs/server/Server.cpp:397
    ClickHouse#50 0x000055555dc994c2 in main (argc_=<optimized out>, argv_=<optimized out>) at /src/ch/clickhouse/programs/main.cpp:340

</details>
Felixoid pushed a commit that referenced this pull request Jul 16, 2025
…ary bridge cleanup

<details>

<summary>stacktrace</summary>

    #5  DB::ContextSharedMutex::lockSharedImpl (this=this@entry=0x7ffff5b96040) at /src/ch/clickhouse/src/Interpreters/Context.cpp:1036
            watch = {start_ns = 98678735300141, stop_ns = 0, clock_type = 4, is_running = true}
            increment = {what = <optimized out>, amount = 1}
    #6  0x00005555699352d6 in DB::SharedMutexHelper<DB::ContextSharedMutex, DB::SharedMutex>::lock_shared (this=0x7ffff5b96040) at /src/ch/clickhouse/src/Common/SharedMutexHelper.h:70
    #7  DB::SharedLockGuard<DB::ContextSharedMutex>::SharedLockGuard (mutex_=..., this=<optimized out>) at /src/ch/clickhouse/src/Common/SharedLockGuard.h:19
    #8  DB::ContextSharedPart::getConfigRef (this=0x7ffff5b96000) at /src/ch/clickhouse/src/Interpreters/Context.cpp:760
    #9  DB::Context::getConfigRef (this=<optimized out>) at /src/ch/clickhouse/src/Interpreters/Context.cpp:1590
    #10 0x000055556450941c in DB::ProxyConfigurationResolverProvider::get (request_protocol=DB::ProxyConfiguration::Protocol::HTTP) at /src/ch/clickhouse/src/Common/ProxyConfigurationResolverProvider.cpp:161
    #11 0x00005555669ea75f in DB::BuilderRWBufferFromHTTP::create (this=0x7fffffffa848, credentials_=...) at /src/ch/clickhouse/src/IO/ReadWriteBufferFromHTTP.cpp:814
    #12 0x000055556cea0035 in DB::ExternalDictionaryLibraryBridgeHelper::bridgeHandShake (this=0x7ffd60c4ca18) at /src/ch/clickhouse/src/BridgeHelper/ExternalDictionaryLibraryBridgeHelper.cpp:79
    #13 0x000055556cea1f34 in DB::ExternalDictionaryLibraryBridgeHelper::removeLibrary (this=0x7ffff5b96044) at /src/ch/clickhouse/src/BridgeHelper/ExternalDictionaryLibraryBridgeHelper.cpp:186
    #14 0x0000555566cb0248 in DB::LibraryDictionarySource::~LibraryDictionarySource (this=0x7ffd60c78318) at /src/ch/clickhouse/src/Dictionaries/LibraryDictionarySource.cpp:70
    #15 0x000055556708d775 in std::__1::__shared_count::__release_shared[abi:ne190107]() (this=0x7ffd60c78300) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:156
    #16 std::__1::__shared_weak_count::__release_shared[abi:ne190107]() (this=0x7ffd60c78300) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:185
    #17 std::__1::shared_ptr<DB::IDictionarySource>::~shared_ptr[abi:ne190107]() (this=0x7ffd60c605b0) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:668
    #18 DB::HashedDictionary<(DB::DictionaryKeyType)0, false, false>::~HashedDictionary (this=0x7ffd60c60398) at /src/ch/clickhouse/src/Dictionaries/HashedDictionary.h:378
    #19 0x0000555569a9c477 in std::__1::__shared_count::__release_shared[abi:ne190107]() (this=0x7ffd60c60380) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:156
    #20 std::__1::__shared_weak_count::__release_shared[abi:ne190107]() (this=0x7ffd60c60380) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:185
    #21 std::__1::shared_ptr<DB::IExternalLoadable>::~shared_ptr[abi:ne190107]() (this=0x7ffff4832560) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:668
    #22 DB::ExternalLoader::LoadingDispatcher::Info::~Info (this=0x7ffff4832548) at /src/ch/clickhouse/src/Interpreters/ExternalLoader.cpp:719
    #23 std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const, DB::ExternalLoader::LoadingDispatcher::Info>::~pair (this=0x7ffff4832530, this@entry=0x7ffd60c60390) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__utility/pair.h:65
    #24 __destroy_at<std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const, DB::ExternalLoader::LoadingDispatcher::Info>, 0> (__loc=__loc@entry=0x7ffff4832530) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/construct_at.h:67
    #25 0x0000555569a9c628 in destroy<std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const, DB::ExternalLoader::LoadingDispatcher::Info>, void, 0> (__p=0x7ffff5b96044, __p@entry=0x7ffff4832530) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/allocator_traits.h:339
    #28 std::__1::unique_ptr<std::__1::__hash_node<std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, DB::ExternalLoader::LoadingDispatcher::Info>, void*>, std::__1::__hash_node_destructor<std::__1::allocator<std::__1::__hash_node<std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, DB::ExternalLoader::LoadingDispatcher::Info>, void*> > > >::~unique_ptr[abi:ne190107]() (this=<optimized out>) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/unique_ptr.h:261
    #31 DB::ExternalLoader::LoadingDispatcher::setConfiguration (this=this@entry=0x7ffecad4c300, new_configs=...) at /src/ch/clickhouse/src/Interpreters/ExternalLoader.cpp:495
    #32 0x0000555569a9116d in DB::ExternalLoader::reloadConfig (this=0x7ffecb3fd740, repository_name=...) at /src/ch/clickhouse/src/Interpreters/ExternalLoader.cpp:1533
    #33 DB::ExternalLoader::addConfigRepository(std::__1::unique_ptr<DB::IExternalLoaderConfigRepository, std::__1::default_delete<DB::IExternalLoaderConfigRepository> >) const::$_0::operator()() const (this=<optimized out>) at /src/ch/clickhouse/src/Interpreters/ExternalLoader.cpp:1334
    #34 std::__1::__invoke[abi:ne190107]<DB::ExternalLoader::addConfigRepository(std::__1::unique_ptr<DB::IExternalLoaderConfigRepository, std::__1::default_delete<DB::IExternalLoaderConfigRepository> >) const::$_0&>(DB::ExternalLoader::addConfigRepository(std::__1::unique_ptr<DB::IExternalLoaderConfigRepository, std::__1::default_delete<DB::IExternalLoaderConfigRepository> >) const::$_0&) (__f=...) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__type_traits/invoke.h:149
    #35 std::__1::__invoke_void_return_wrapper<void, true>::__call[abi:ne190107]<DB::ExternalLoader::addConfigRepository(std::__1::unique_ptr<DB::IExternalLoaderConfigRepository, std::__1::default_delete<DB::IExternalLoaderConfigRepository> >) const::$_0&>(DB::ExternalLoader::addConfigRepository(std::__1::unique_ptr<DB::IExternalLoaderConfigRepository, std::__1::default_delete<DB::IExternalLoaderConfigRepository> >) const::$_0&) (__args=...) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__type_traits/invoke.h:224
    #36 std::__1::__function::__default_alloc_func<DB::ExternalLoader::addConfigRepository(std::__1::unique_ptr<DB::IExternalLoaderConfigRepository, std::__1::default_delete<DB::IExternalLoaderConfigRepository> >) const::$_0, void ()>::operator()[abi:ne190107]() (this=<optimized out>) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__functional/function.h:210
    #37 std::__1::__function::__policy_invoker<void ()>::__call_impl[abi:ne190107]<std::__1::__function::__default_alloc_func<DB::ExternalLoader::addConfigRepository(std::__1::unique_ptr<DB::IExternalLoaderConfigRepository, std::__1::default_delete<DB::IExternalLoaderConfigRepository> >) const::$_0, void ()> #38 0x0000555569966aaa in std::__1::__function::__policy_func<void ()>::operator()[abi:ne190107]() const (this=0x7ffff5b96044) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__functional/function.h:716
    #39 std::__1::function<void()>::operator() (this=0x7ffff5b96044) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__functional/function.h:989
    #40 BasicScopeGuard<std::__1::function<void()> >::invoke (this=0x7ffff5b96044) at /src/ch/clickhouse/base/base/../base/scope_guard.h:101
    #41 BasicScopeGuard<std::__1::function<void()> >::reset (this=0x7ffff5b96044) at /src/ch/clickhouse/base/base/../base/scope_guard.h:63
    #42 DB::ContextSharedPart::shutdown (this=0x7ffff5b96000) at /src/ch/clickhouse/src/Interpreters/Context.cpp:909
    #43 0x00005555644cf5cb in DB::Server::main(std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&)::$_3::operator()() const (this=this@entry=0x7fffffffc870) at /src/ch/clickhouse/programs/server/Server.cpp:1257
    #44 0x00005555644b4439 in BasicScopeGuard<DB::Server::main(std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&)::$_3>::invoke (this=0x7fffffffc870) at /src/ch/clickhouse/base/base/../base/scope_guard.h:101
    #45 BasicScopeGuard<DB::Server::main(std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&)::$_3>::~BasicScopeGuard (this=0x7fffffffc870) at /src/ch/clickhouse/base/base/../base/scope_guard.h:50
    #46 DB::Server::main (this=0x7fffffffe4c8) at /src/ch/clickhouse/programs/server/Server.cpp:2788
    #47 0x0000555572cbbee9 in Poco::Util::Application::run (this=0x7fffffffe4c8) at /src/ch/clickhouse/base/poco/Util/src/Application.cpp:315
    #48 0x000055556449c390 in DB::Server::run (this=0x7fffffffe4c8) at /src/ch/clickhouse/programs/server/Server.cpp:610
    #49 0x0000555564499aec in mainEntryClickHouseServer (argc=6, argv=0x7ffff67ecdc0) at /src/ch/clickhouse/programs/server/Server.cpp:397
    #50 0x000055555dc994c2 in main (argc_=<optimized out>, argv_=<optimized out>) at /src/ch/clickhouse/programs/main.cpp:340

</details>
Felixoid pushed a commit that referenced this pull request Jul 16, 2025
…ary bridge cleanup

<details>

<summary>stacktrace</summary>

    #5  DB::ContextSharedMutex::lockSharedImpl (this=this@entry=0x7ffff5b96040) at /src/ch/clickhouse/src/Interpreters/Context.cpp:1036
            watch = {start_ns = 98678735300141, stop_ns = 0, clock_type = 4, is_running = true}
            increment = {what = <optimized out>, amount = 1}
    #6  0x00005555699352d6 in DB::SharedMutexHelper<DB::ContextSharedMutex, DB::SharedMutex>::lock_shared (this=0x7ffff5b96040) at /src/ch/clickhouse/src/Common/SharedMutexHelper.h:70
    #7  DB::SharedLockGuard<DB::ContextSharedMutex>::SharedLockGuard (mutex_=..., this=<optimized out>) at /src/ch/clickhouse/src/Common/SharedLockGuard.h:19
    #8  DB::ContextSharedPart::getConfigRef (this=0x7ffff5b96000) at /src/ch/clickhouse/src/Interpreters/Context.cpp:760
    #9  DB::Context::getConfigRef (this=<optimized out>) at /src/ch/clickhouse/src/Interpreters/Context.cpp:1590
    #10 0x000055556450941c in DB::ProxyConfigurationResolverProvider::get (request_protocol=DB::ProxyConfiguration::Protocol::HTTP) at /src/ch/clickhouse/src/Common/ProxyConfigurationResolverProvider.cpp:161
    #11 0x00005555669ea75f in DB::BuilderRWBufferFromHTTP::create (this=0x7fffffffa848, credentials_=...) at /src/ch/clickhouse/src/IO/ReadWriteBufferFromHTTP.cpp:814
    #12 0x000055556cea0035 in DB::ExternalDictionaryLibraryBridgeHelper::bridgeHandShake (this=0x7ffd60c4ca18) at /src/ch/clickhouse/src/BridgeHelper/ExternalDictionaryLibraryBridgeHelper.cpp:79
    #13 0x000055556cea1f34 in DB::ExternalDictionaryLibraryBridgeHelper::removeLibrary (this=0x7ffff5b96044) at /src/ch/clickhouse/src/BridgeHelper/ExternalDictionaryLibraryBridgeHelper.cpp:186
    #14 0x0000555566cb0248 in DB::LibraryDictionarySource::~LibraryDictionarySource (this=0x7ffd60c78318) at /src/ch/clickhouse/src/Dictionaries/LibraryDictionarySource.cpp:70
    #15 0x000055556708d775 in std::__1::__shared_count::__release_shared[abi:ne190107]() (this=0x7ffd60c78300) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:156
    #16 std::__1::__shared_weak_count::__release_shared[abi:ne190107]() (this=0x7ffd60c78300) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:185
    #17 std::__1::shared_ptr<DB::IDictionarySource>::~shared_ptr[abi:ne190107]() (this=0x7ffd60c605b0) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:668
    #18 DB::HashedDictionary<(DB::DictionaryKeyType)0, false, false>::~HashedDictionary (this=0x7ffd60c60398) at /src/ch/clickhouse/src/Dictionaries/HashedDictionary.h:378
    #19 0x0000555569a9c477 in std::__1::__shared_count::__release_shared[abi:ne190107]() (this=0x7ffd60c60380) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:156
    #20 std::__1::__shared_weak_count::__release_shared[abi:ne190107]() (this=0x7ffd60c60380) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:185
    #21 std::__1::shared_ptr<DB::IExternalLoadable>::~shared_ptr[abi:ne190107]() (this=0x7ffff4832560) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:668
    #22 DB::ExternalLoader::LoadingDispatcher::Info::~Info (this=0x7ffff4832548) at /src/ch/clickhouse/src/Interpreters/ExternalLoader.cpp:719
    #23 std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const, DB::ExternalLoader::LoadingDispatcher::Info>::~pair (this=0x7ffff4832530, this@entry=0x7ffd60c60390) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__utility/pair.h:65
    #24 __destroy_at<std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const, DB::ExternalLoader::LoadingDispatcher::Info>, 0> (__loc=__loc@entry=0x7ffff4832530) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/construct_at.h:67
    #25 0x0000555569a9c628 in destroy<std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const, DB::ExternalLoader::LoadingDispatcher::Info>, void, 0> (__p=0x7ffff5b96044, __p@entry=0x7ffff4832530) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/allocator_traits.h:339
    #28 std::__1::unique_ptr<std::__1::__hash_node<std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, DB::ExternalLoader::LoadingDispatcher::Info>, void*>, std::__1::__hash_node_destructor<std::__1::allocator<std::__1::__hash_node<std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, DB::ExternalLoader::LoadingDispatcher::Info>, void*> > > >::~unique_ptr[abi:ne190107]() (this=<optimized out>) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/unique_ptr.h:261
    #31 DB::ExternalLoader::LoadingDispatcher::setConfiguration (this=this@entry=0x7ffecad4c300, new_configs=...) at /src/ch/clickhouse/src/Interpreters/ExternalLoader.cpp:495
    #32 0x0000555569a9116d in DB::ExternalLoader::reloadConfig (this=0x7ffecb3fd740, repository_name=...) at /src/ch/clickhouse/src/Interpreters/ExternalLoader.cpp:1533
    #33 DB::ExternalLoader::addConfigRepository(std::__1::unique_ptr<DB::IExternalLoaderConfigRepository, std::__1::default_delete<DB::IExternalLoaderConfigRepository> >) const::$_0::operator()() const (this=<optimized out>) at /src/ch/clickhouse/src/Interpreters/ExternalLoader.cpp:1334
    #34 std::__1::__invoke[abi:ne190107]<DB::ExternalLoader::addConfigRepository(std::__1::unique_ptr<DB::IExternalLoaderConfigRepository, std::__1::default_delete<DB::IExternalLoaderConfigRepository> >) const::$_0&>(DB::ExternalLoader::addConfigRepository(std::__1::unique_ptr<DB::IExternalLoaderConfigRepository, std::__1::default_delete<DB::IExternalLoaderConfigRepository> >) const::$_0&) (__f=...) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__type_traits/invoke.h:149
    #35 std::__1::__invoke_void_return_wrapper<void, true>::__call[abi:ne190107]<DB::ExternalLoader::addConfigRepository(std::__1::unique_ptr<DB::IExternalLoaderConfigRepository, std::__1::default_delete<DB::IExternalLoaderConfigRepository> >) const::$_0&>(DB::ExternalLoader::addConfigRepository(std::__1::unique_ptr<DB::IExternalLoaderConfigRepository, std::__1::default_delete<DB::IExternalLoaderConfigRepository> >) const::$_0&) (__args=...) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__type_traits/invoke.h:224
    #36 std::__1::__function::__default_alloc_func<DB::ExternalLoader::addConfigRepository(std::__1::unique_ptr<DB::IExternalLoaderConfigRepository, std::__1::default_delete<DB::IExternalLoaderConfigRepository> >) const::$_0, void ()>::operator()[abi:ne190107]() (this=<optimized out>) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__functional/function.h:210
    #37 std::__1::__function::__policy_invoker<void ()>::__call_impl[abi:ne190107]<std::__1::__function::__default_alloc_func<DB::ExternalLoader::addConfigRepository(std::__1::unique_ptr<DB::IExternalLoaderConfigRepository, std::__1::default_delete<DB::IExternalLoaderConfigRepository> >) const::$_0, void ()> #38 0x0000555569966aaa in std::__1::__function::__policy_func<void ()>::operator()[abi:ne190107]() const (this=0x7ffff5b96044) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__functional/function.h:716
    #39 std::__1::function<void()>::operator() (this=0x7ffff5b96044) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__functional/function.h:989
    #40 BasicScopeGuard<std::__1::function<void()> >::invoke (this=0x7ffff5b96044) at /src/ch/clickhouse/base/base/../base/scope_guard.h:101
    #41 BasicScopeGuard<std::__1::function<void()> >::reset (this=0x7ffff5b96044) at /src/ch/clickhouse/base/base/../base/scope_guard.h:63
    #42 DB::ContextSharedPart::shutdown (this=0x7ffff5b96000) at /src/ch/clickhouse/src/Interpreters/Context.cpp:909
    #43 0x00005555644cf5cb in DB::Server::main(std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&)::$_3::operator()() const (this=this@entry=0x7fffffffc870) at /src/ch/clickhouse/programs/server/Server.cpp:1257
    #44 0x00005555644b4439 in BasicScopeGuard<DB::Server::main(std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&)::$_3>::invoke (this=0x7fffffffc870) at /src/ch/clickhouse/base/base/../base/scope_guard.h:101
    #45 BasicScopeGuard<DB::Server::main(std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&)::$_3>::~BasicScopeGuard (this=0x7fffffffc870) at /src/ch/clickhouse/base/base/../base/scope_guard.h:50
    #46 DB::Server::main (this=0x7fffffffe4c8) at /src/ch/clickhouse/programs/server/Server.cpp:2788
    #47 0x0000555572cbbee9 in Poco::Util::Application::run (this=0x7fffffffe4c8) at /src/ch/clickhouse/base/poco/Util/src/Application.cpp:315
    #48 0x000055556449c390 in DB::Server::run (this=0x7fffffffe4c8) at /src/ch/clickhouse/programs/server/Server.cpp:610
    #49 0x0000555564499aec in mainEntryClickHouseServer (argc=6, argv=0x7ffff67ecdc0) at /src/ch/clickhouse/programs/server/Server.cpp:397
    #50 0x000055555dc994c2 in main (argc_=<optimized out>, argv_=<optimized out>) at /src/ch/clickhouse/programs/main.cpp:340

</details>
Felixoid pushed a commit that referenced this pull request Jul 16, 2025
…ary bridge cleanup

<details>

<summary>stacktrace</summary>

    #5  DB::ContextSharedMutex::lockSharedImpl (this=this@entry=0x7ffff5b96040) at /src/ch/clickhouse/src/Interpreters/Context.cpp:1036
            watch = {start_ns = 98678735300141, stop_ns = 0, clock_type = 4, is_running = true}
            increment = {what = <optimized out>, amount = 1}
    #6  0x00005555699352d6 in DB::SharedMutexHelper<DB::ContextSharedMutex, DB::SharedMutex>::lock_shared (this=0x7ffff5b96040) at /src/ch/clickhouse/src/Common/SharedMutexHelper.h:70
    #7  DB::SharedLockGuard<DB::ContextSharedMutex>::SharedLockGuard (mutex_=..., this=<optimized out>) at /src/ch/clickhouse/src/Common/SharedLockGuard.h:19
    #8  DB::ContextSharedPart::getConfigRef (this=0x7ffff5b96000) at /src/ch/clickhouse/src/Interpreters/Context.cpp:760
    #9  DB::Context::getConfigRef (this=<optimized out>) at /src/ch/clickhouse/src/Interpreters/Context.cpp:1590
    #10 0x000055556450941c in DB::ProxyConfigurationResolverProvider::get (request_protocol=DB::ProxyConfiguration::Protocol::HTTP) at /src/ch/clickhouse/src/Common/ProxyConfigurationResolverProvider.cpp:161
    #11 0x00005555669ea75f in DB::BuilderRWBufferFromHTTP::create (this=0x7fffffffa848, credentials_=...) at /src/ch/clickhouse/src/IO/ReadWriteBufferFromHTTP.cpp:814
    #12 0x000055556cea0035 in DB::ExternalDictionaryLibraryBridgeHelper::bridgeHandShake (this=0x7ffd60c4ca18) at /src/ch/clickhouse/src/BridgeHelper/ExternalDictionaryLibraryBridgeHelper.cpp:79
    #13 0x000055556cea1f34 in DB::ExternalDictionaryLibraryBridgeHelper::removeLibrary (this=0x7ffff5b96044) at /src/ch/clickhouse/src/BridgeHelper/ExternalDictionaryLibraryBridgeHelper.cpp:186
    #14 0x0000555566cb0248 in DB::LibraryDictionarySource::~LibraryDictionarySource (this=0x7ffd60c78318) at /src/ch/clickhouse/src/Dictionaries/LibraryDictionarySource.cpp:70
    #15 0x000055556708d775 in std::__1::__shared_count::__release_shared[abi:ne190107]() (this=0x7ffd60c78300) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:156
    #16 std::__1::__shared_weak_count::__release_shared[abi:ne190107]() (this=0x7ffd60c78300) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:185
    #17 std::__1::shared_ptr<DB::IDictionarySource>::~shared_ptr[abi:ne190107]() (this=0x7ffd60c605b0) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:668
    #18 DB::HashedDictionary<(DB::DictionaryKeyType)0, false, false>::~HashedDictionary (this=0x7ffd60c60398) at /src/ch/clickhouse/src/Dictionaries/HashedDictionary.h:378
    #19 0x0000555569a9c477 in std::__1::__shared_count::__release_shared[abi:ne190107]() (this=0x7ffd60c60380) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:156
    #20 std::__1::__shared_weak_count::__release_shared[abi:ne190107]() (this=0x7ffd60c60380) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:185
    #21 std::__1::shared_ptr<DB::IExternalLoadable>::~shared_ptr[abi:ne190107]() (this=0x7ffff4832560) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/shared_ptr.h:668
    #22 DB::ExternalLoader::LoadingDispatcher::Info::~Info (this=0x7ffff4832548) at /src/ch/clickhouse/src/Interpreters/ExternalLoader.cpp:719
    #23 std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const, DB::ExternalLoader::LoadingDispatcher::Info>::~pair (this=0x7ffff4832530, this@entry=0x7ffd60c60390) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__utility/pair.h:65
    #24 __destroy_at<std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const, DB::ExternalLoader::LoadingDispatcher::Info>, 0> (__loc=__loc@entry=0x7ffff4832530) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/construct_at.h:67
    #25 0x0000555569a9c628 in destroy<std::__1::pair<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > const, DB::ExternalLoader::LoadingDispatcher::Info>, void, 0> (__p=0x7ffff5b96044, __p@entry=0x7ffff4832530) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/allocator_traits.h:339
    #28 std::__1::unique_ptr<std::__1::__hash_node<std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, DB::ExternalLoader::LoadingDispatcher::Info>, void*>, std::__1::__hash_node_destructor<std::__1::allocator<std::__1::__hash_node<std::__1::__hash_value_type<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, DB::ExternalLoader::LoadingDispatcher::Info>, void*> > > >::~unique_ptr[abi:ne190107]() (this=<optimized out>) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__memory/unique_ptr.h:261
    #31 DB::ExternalLoader::LoadingDispatcher::setConfiguration (this=this@entry=0x7ffecad4c300, new_configs=...) at /src/ch/clickhouse/src/Interpreters/ExternalLoader.cpp:495
    #32 0x0000555569a9116d in DB::ExternalLoader::reloadConfig (this=0x7ffecb3fd740, repository_name=...) at /src/ch/clickhouse/src/Interpreters/ExternalLoader.cpp:1533
    #33 DB::ExternalLoader::addConfigRepository(std::__1::unique_ptr<DB::IExternalLoaderConfigRepository, std::__1::default_delete<DB::IExternalLoaderConfigRepository> >) const::$_0::operator()() const (this=<optimized out>) at /src/ch/clickhouse/src/Interpreters/ExternalLoader.cpp:1334
    #34 std::__1::__invoke[abi:ne190107]<DB::ExternalLoader::addConfigRepository(std::__1::unique_ptr<DB::IExternalLoaderConfigRepository, std::__1::default_delete<DB::IExternalLoaderConfigRepository> >) const::$_0&>(DB::ExternalLoader::addConfigRepository(std::__1::unique_ptr<DB::IExternalLoaderConfigRepository, std::__1::default_delete<DB::IExternalLoaderConfigRepository> >) const::$_0&) (__f=...) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__type_traits/invoke.h:149
    #35 std::__1::__invoke_void_return_wrapper<void, true>::__call[abi:ne190107]<DB::ExternalLoader::addConfigRepository(std::__1::unique_ptr<DB::IExternalLoaderConfigRepository, std::__1::default_delete<DB::IExternalLoaderConfigRepository> >) const::$_0&>(DB::ExternalLoader::addConfigRepository(std::__1::unique_ptr<DB::IExternalLoaderConfigRepository, std::__1::default_delete<DB::IExternalLoaderConfigRepository> >) const::$_0&) (__args=...) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__type_traits/invoke.h:224
    #36 std::__1::__function::__default_alloc_func<DB::ExternalLoader::addConfigRepository(std::__1::unique_ptr<DB::IExternalLoaderConfigRepository, std::__1::default_delete<DB::IExternalLoaderConfigRepository> >) const::$_0, void ()>::operator()[abi:ne190107]() (this=<optimized out>) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__functional/function.h:210
    #37 std::__1::__function::__policy_invoker<void ()>::__call_impl[abi:ne190107]<std::__1::__function::__default_alloc_func<DB::ExternalLoader::addConfigRepository(std::__1::unique_ptr<DB::IExternalLoaderConfigRepository, std::__1::default_delete<DB::IExternalLoaderConfigRepository> >) const::$_0, void ()> #38 0x0000555569966aaa in std::__1::__function::__policy_func<void ()>::operator()[abi:ne190107]() const (this=0x7ffff5b96044) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__functional/function.h:716
    #39 std::__1::function<void()>::operator() (this=0x7ffff5b96044) at /src/ch/clickhouse/contrib/llvm-project/libcxx/include/__functional/function.h:989
    #40 BasicScopeGuard<std::__1::function<void()> >::invoke (this=0x7ffff5b96044) at /src/ch/clickhouse/base/base/../base/scope_guard.h:101
    #41 BasicScopeGuard<std::__1::function<void()> >::reset (this=0x7ffff5b96044) at /src/ch/clickhouse/base/base/../base/scope_guard.h:63
    #42 DB::ContextSharedPart::shutdown (this=0x7ffff5b96000) at /src/ch/clickhouse/src/Interpreters/Context.cpp:909
    #43 0x00005555644cf5cb in DB::Server::main(std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&)::$_3::operator()() const (this=this@entry=0x7fffffffc870) at /src/ch/clickhouse/programs/server/Server.cpp:1257
    #44 0x00005555644b4439 in BasicScopeGuard<DB::Server::main(std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&)::$_3>::invoke (this=0x7fffffffc870) at /src/ch/clickhouse/base/base/../base/scope_guard.h:101
    #45 BasicScopeGuard<DB::Server::main(std::__1::vector<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >, std::__1::allocator<std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> > > > const&)::$_3>::~BasicScopeGuard (this=0x7fffffffc870) at /src/ch/clickhouse/base/base/../base/scope_guard.h:50
    #46 DB::Server::main (this=0x7fffffffe4c8) at /src/ch/clickhouse/programs/server/Server.cpp:2788
    #47 0x0000555572cbbee9 in Poco::Util::Application::run (this=0x7fffffffe4c8) at /src/ch/clickhouse/base/poco/Util/src/Application.cpp:315
    #48 0x000055556449c390 in DB::Server::run (this=0x7fffffffe4c8) at /src/ch/clickhouse/programs/server/Server.cpp:610
    #49 0x0000555564499aec in mainEntryClickHouseServer (argc=6, argv=0x7ffff67ecdc0) at /src/ch/clickhouse/programs/server/Server.cpp:397
    #50 0x000055555dc994c2 in main (argc_=<optimized out>, argv_=<optimized out>) at /src/ch/clickhouse/programs/main.cpp:340

</details>
Ted-Jiang added a commit to Ted-Jiang/ClickHouse that referenced this pull request Jan 8, 2026
…memory and Avoid tons of memory copy (ClickHouse#22)

* Add log to print out iceberg partition info

* minor fix

* print related thread info

* Try to list all task into memory and avoid get global lock.

* make it default false

* make iceberg metadata cache more specific

* change blocking_queue size

* Make ManifestFileEntry less copy

* Make ManifestFileEntry non-copyable
Onyx2406 pushed a commit to Onyx2406/ClickHouse that referenced this pull request Mar 19, 2026
…TTPS support, fix command (ClickHouse#22)

* Add an option to create a cloud client with a random database

* Add HTTPS support, use Cloud for INSERT integration test

* Add CLICKHOUSE_CLOUD_ENABLED env variable to CI

* Simplify test client creation

* Add env variables from secrets

* Local ClickHouse cluster configuration (ClickHouse#33)

* Local ClickHouse cluster configuration

* Fix `command` and related tests, use more flexible test env, rename configs
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants