Commit Graph

80472 Commits

Author SHA1 Message Date
Azat Khuzhin
5ed7440381 Fix possible use-after-free for INSERT into MV with concurrent DROP
ASan founds [1]:

    ==553==
    ERROR: AddressSanitizer: heap-use-after-free on address 0x61e004694080 at pc 0x000029150af2 bp 0x7f70b3f8ef10 sp 0x7f70b3f8ef08
    READ of size 8 at 0x61e004694080 thread T477 (QueryPipelineEx)
        0 0x29150af1 in DB::MergeTreeDataWriter::writeTempPart() >
        1 0x293b8e43 in DB::MergeTreeSink::consume(DB::Chunk) obj-x86_64-linux-gnu/../src/Storages/MergeTree/MergeTreeSink.cpp:27:65
        2 0x29dac73b in DB::SinkToStorage::onConsume(DB::Chunk) obj-x86_64-linux-gnu/../src/Processors/Sinks/SinkToStorage.cpp:18:5
        3 0x29c72dd2 in DB::ExceptionKeepingTransform::work()::$_1::operator()() const obj-x86_64-linux-gnu/../src/Processors/Transforms/ExceptionKeepingTransform.cpp:151:51

    0x61e004694080 is located 2048 bytes inside of 2480-byte region [0x61e004693880,0x61e004694230)
    freed by thread T199 (BgSchPool) here:
        ...
        4 0x26220f20 in DB::DatabaseCatalog::TableMarkedAsDropped::~TableMarkedAsDropped() obj-x86_64-linux-gnu/../src/Interpreters/DatabaseCatalog.h:248:12
        5 0x26220f20 in DB::DatabaseCatalog::dropTableDataTask() obj-x86_64-linux-gnu/../src/Interpreters/DatabaseCatalog.cpp:908:1

      [1]: https://s3.amazonaws.com/clickhouse-test-reports/33201/4f04d6af61eabf4899eb8188150dc862aaab80fc/stress_test__address__actions_.html

There was a fix in #32572, but it was not complete (yes it reduced the
race window a lot, but not completely), since the inner table still can
go away after the INSERT chain was built, to fix this obtain the
reference earlier.

Follow-up for: #32572 (cc @tavplubix)
2022-01-04 13:34:01 +03:00
alexey-milovidov
b5ee8cb694
Merge pull request #33374 from den-crane/patch-55
Doc. No need to double backslashes (\\)
2022-01-03 23:51:08 +03:00
Denny Crane
7261e121dd
Update string-search-functions.md 2022-01-03 16:19:54 -04:00
Nikita Mikhaylov
659f502ce5
Merge pull request #33346 from amosbird/blobstoragebuildfix2 2022-01-03 21:17:09 +04:00
alexey-milovidov
6efe73fc1b
Merge pull request #26559 from nikitamikhaylov/merging-dev-sum-bug
Merging #26074
2022-01-03 19:46:54 +03:00
alexey-milovidov
cb19d6f519
Merge pull request #29953 from amosbird/saturatetime
Saturate date/datetime to zero.
2022-01-03 19:44:33 +03:00
alesapin
9619b0fd96
Merge pull request #33336 from ClickHouse/fix-diff-encoding
Fix (?) encoding issue in #33331
2022-01-03 15:17:22 +03:00
alexey-milovidov
bc1ac93d4d
Update AggregateFunctionNothing.cpp 2022-01-03 14:19:16 +03:00
Maksim Kita
5ae10e5e31
Merge pull request #33369 from benbiti/docs_zh_create_function
[Docs-zh]translate create function into zh
2022-01-03 14:11:22 +03:00
Maksim Kita
c3521bfdf9
Merge pull request #33343 from azat/tests-new-kafka-formats
Cover CustomSeparated/Template formats for Kafka
2022-01-03 14:04:36 +03:00
Maksim Kita
4363865757
Merge pull request #33339 from freedomDR/add_doc_settings
docs setting shutdown wait time add comment
2022-01-03 14:02:55 +03:00
alexey-milovidov
7feed04c9a
Update AggregateFunctionNothing.h 2022-01-03 03:59:45 +03:00
alexey-milovidov
fbadbc8cba
Update AggregateFunctionNothing.h 2022-01-03 03:59:29 +03:00
alexey-milovidov
bd002a6d50
Update AggregateFunctionNothing.cpp 2022-01-03 03:58:18 +03:00
alexey-milovidov
141696e146
Update AggregateFunctionNothing.cpp 2022-01-03 03:53:39 +03:00
alexey-milovidov
f0d2838a5b
Update AggregateFunctionNothing.h 2022-01-03 03:52:39 +03:00
alexey-milovidov
d77a4eb093
Update CODEOWNERS 2022-01-03 02:08:36 +03:00
Alexey Milovidov
cab5f4fe1e Merge with master 2022-01-03 02:07:08 +03:00
Amos Bird
0b7a94c2be Saturate date/datetime to zero 2022-01-03 02:07:08 +03:00
Maksim Kita
e0a091d068
Merge pull request #33337 from anselmodadams/patch-1
Documentation fix - incorrect CREATE DICTIONARY statement order
2022-01-02 20:15:04 +03:00
Maksim Kita
1ab66d26c0
Merge pull request #33363 from kitaisreal/user-defined-executable-function-fix-docs
UserDefinedExecutableFunction fix documentation
2022-01-02 20:03:30 +03:00
Maksim Kita
8e83f2d154 Updated documentation 2022-01-02 20:02:53 +03:00
Maksim Kita
106e742f98
Merge pull request #33362 from kitaisreal/user-defined-executable-function-fix-exception
UserDefinedExecutableFunction fix exception
2022-01-02 19:58:28 +03:00
Maksim Kita
4f62155b84 UserDefinedExecutableFunction fix documentation 2022-01-02 16:46:11 +03:00
Maksim Kita
a7d0f3e637 UserDefinedExecutableFunction fix exception 2022-01-02 16:21:52 +03:00
Maksim Kita
36beb6c2f3
Merge pull request #33338 from benbiti/update_zh_docs_note_tag
[Docs-zh]update zh docs note tag
2022-01-02 16:14:56 +03:00
Ilya Yatsishin
b29e8688a5
Merge pull request #33353 from bharatnc/ncb/update-copyright 2022-01-01 10:04:15 +03:00
benbiti
c8866feecc [Docs-zh]translate create function into zh 2022-01-01 10:56:42 +08:00
bharatnc
fcff7f4dc1 update copyright in docs 2021-12-31 16:22:17 -08:00
Ilya Yatsishin
f967bcdee9
Merge pull request #33143 from VitalyArt/patch-1 2021-12-31 21:28:40 +03:00
Amos Bird
e6f4427a68
Fix 2021-12-31 20:53:03 +08:00
Amos Bird
a4558a3135
Fix blob_storage build 2021-12-31 20:28:27 +08:00
alexey-milovidov
3f1810c049
Merge pull request #33327 from ClickHouse/rename_committed_to_active
Rename Committed data part state to Active
2021-12-31 14:40:35 +03:00
alexey-milovidov
c2ed92d75d
Update pr_info.py 2021-12-31 14:39:28 +03:00
alexey-milovidov
34b934a1e0
Merge pull request #33331 from ClickHouse/serxa/line-as-string-output-format
Add LineAsString output format
2021-12-31 14:38:36 +03:00
alexey-milovidov
3737d83d3e
Merge pull request #33333 from ClickHouse/add-access-control-to-system-commands
Add missing access control to some system commands
2021-12-31 14:36:59 +03:00
alexey-milovidov
6941b072f4
Merge pull request #33330 from cmsxbc/support-self-closing-tag-for-cluster-secure
support `<secure/>` in cluster configuration.
2021-12-31 14:36:19 +03:00
Azat Khuzhin
63eac4b0cf tests/integration/test_storage_kafka: cover CustomSeparated 2021-12-31 12:02:21 +03:00
Azat Khuzhin
f1c726a675 tests/integration/test_storage_kafka: cover Template format 2021-12-31 11:25:08 +03:00
Kseniia Sumarokova
a3b30dce32
Merge pull request #33334 from kssenii/follow-up-for-33098
Tiny follow-up to pr 33098
2021-12-31 11:11:02 +03:00
freedomDR
c0072c6db0 docs setting add shutdown_wait_unfinished_queries shutdown_wait_unfinished config 2021-12-31 02:56:20 +00:00
benbiti
b347e8356c [Docs-zh]update zh docs note tag 2021-12-31 10:46:07 +08:00
SuperDJY
4322fd4bdb
avoid underscore in gtest name 2021-12-31 10:19:03 +08:00
SuperDJY
4c36657926
link clickhouse_common_config to unit_test_dbms 2021-12-31 10:17:17 +08:00
cmsxbc
fd9f1193d8
use .empty() instead of .size() == 0 2021-12-31 08:30:21 +08:00
Anselmo D. Adams
883b83acb0
Update dictionary.md 2021-12-30 19:43:54 -03:00
Anselmo D. Adams
5df89e978e
Update dictionary.md
Fixed order of DICTIONARY term in create statement
2021-12-30 19:33:31 -03:00
Mikhail f. Shiryaev
fccc4dade1
Fix (?) encoding issue in #33331 2021-12-30 22:19:06 +01:00
alexey-milovidov
764631f2d4
Update 02157_line_as_string_output_format.reference 2021-12-30 23:49:53 +03:00
alexey-milovidov
9fcfc5c188
Update 02157_line_as_string_output_format.sql 2021-12-30 23:49:36 +03:00