Commit Graph

4915 Commits

Author SHA1 Message Date
root
f4b7cae998 optimize limit 1,0 and test. 2019-09-18 02:55:59 +08:00
chertus
2b3a4b0650 support const and LC columns in partial merge-join 2019-09-17 21:53:52 +03:00
chertus
58fad78980 support MergeJoin nullable convertion (right side) 2019-09-17 19:55:11 +03:00
Dmitry Rubashkin
2252ee5a90 Branch refactoring. 2019-09-17 11:17:46 +03:00
chertus
da5d35b34e partial merge join (minimal tested version) 2019-09-16 22:31:22 +03:00
Dmitry Rubashkin
6f68cfc45c Removed (most probably) redundant if branch. Fixed VALUES table funtion. 2019-09-16 18:44:12 +03:00
chertus
cbd96af079 fix use after free (change Join <-> AnalyzedJoin ownership) 2019-09-16 15:37:46 +03:00
Vitaly Baranov
fae612c3e7
Merge pull request #6907 from PerformanceVision/dict_allow_databases
Whitelist for dictionary from the current connected database
2019-09-16 11:52:25 +03:00
malkfilipp
98050c108f Add LIMIT clause to SHOW queries 2019-09-15 19:07:27 +03:00
Ivan Lezhankin
01fdb802d4 Useful changes 2019-09-15 13:35:12 +03:00
alexey-milovidov
831eebe4dc
Merge pull request #6934 from abyss7/CLICKHOUSE-4643
Name temporary external table with existing subquery alias
2019-09-15 09:46:10 +03:00
Vitaly Baranov
a2c9bec468
Fix typo 2019-09-15 01:56:37 +03:00
Vitaly Baranov
c17071caf0
Fix typo 2019-09-15 01:55:22 +03:00
Vitaly Baranov
0fb234c63e
Merge branch 'master' into dict_allow_databases 2019-09-15 01:51:44 +03:00
Dmitry Rubashkin
33e7e1ea93 Int64 added. 2019-09-13 21:25:53 +03:00
Dmitry Rubashkin
2705534be7 Merge branch 'enums_in_section' of github.com:dimarub2000/ClickHouse into enums_in_section 2019-09-13 20:50:53 +03:00
Dmitry Rubashkin
cd95e8e5e5 Fix inconsistent behaviour of IN with Enums 2019-09-13 20:49:53 +03:00
chertus
eb3d87032c all|any left|inner, not tested 2019-09-13 20:23:32 +03:00
chertus
bd957168d2 any left join (without use_nulls) 2019-09-13 19:17:37 +03:00
Ivan Lezhankin
dc49303baf Use existing alias as external table name 2019-09-13 16:25:24 +03:00
alesapin
02cff38fef Merge with master 2019-09-13 13:58:23 +03:00
Nikolai Kochetov
86bee0b8b5
Merge pull request #6684 from yandex/processors-2
Processors 2
2019-09-13 11:58:04 +03:00
Guillaume Tassery
214d089bb5 Cosmetic and remove documentation 2019-09-13 10:26:04 +02:00
Guillaume Tassery
bb088fbf65 Write dictionary permission on user instead of dictionary configuration 2019-09-13 10:22:34 +02:00
alexey-milovidov
12c26e6013
Merge pull request #6891 from yandex/low_cardinality_in_native_http
Low cardinality in native http
2019-09-13 09:01:08 +03:00
chertus
bb5287841f make things wrong 2 2019-09-12 21:06:25 +03:00
chertus
f7f2cface9 better nullability flags for JOINs 2019-09-12 17:09:05 +03:00
Nikolai Kochetov
1319168a3a Merge branch 'master' into processors-2 2019-09-12 16:28:51 +03:00
Nikolai Kochetov
9dea55c284 Do not pin sources for non MergeTree tables. 2019-09-12 16:23:24 +03:00
chertus
441faba0e3 materializeBlockInplace function 2019-09-12 15:59:53 +03:00
chertus
61c940d5a9 better materialization logic in Join.cpp 2019-09-12 15:24:19 +03:00
chertus
fc7ce2753d extract more common join functions 2019-09-11 21:03:21 +03:00
alesapin
b0fce77c3d Fix path to data on disk 2019-09-11 20:17:10 +03:00
chertus
a836f0cfd6 fix columns number in MergeJoin 2019-09-11 19:19:33 +03:00
chertus
73dafaa223 better required-right-keys logic 2019-09-11 18:57:09 +03:00
Nikolai Kochetov
a2248868d8 Fix ast type checking. 2019-09-11 18:37:12 +03:00
Nikolai Kochetov
a59ae3826d Do not flush output stream in copy data. Add special flushing callback to Watch query. 2019-09-11 14:38:05 +03:00
Nikolai Kochetov
96f7eb1141 Change number of aggregating streams. 2019-09-11 13:07:04 +03:00
Amos Bird
8f28a36c17 Use internal iteration over hash tables in Aggregator.
For compound hash tables such as the future StringHashMap, an
iterator-based API might be inefficient for iterating over a table or
for merging two tables, because:

1) the key has to be converted to a general format from a from a
   component-specific format, which may differ between the components;

2) the information about the component of the compound hash table to
   which the value belongs is lost, and has to be recalculated if the
   value is reinserted.

A more efficient approach is to use internal iteration, that is,
map-like functions, which avoids unnecessary conversions when iterating,
and allows to use an efficient component-wise approach when merging.
2019-09-10 21:52:53 +03:00
chertus
8afa48fa42 some joins code unification 2019-09-10 21:39:10 +03:00
Alexander Kuzmenkov
160e0faf77 Do not use iterator::getValue() in Aggregator.
Use separate key and "mapped" value references instead. This is
important for hash tables that do not store the key/"mapped" pair
directly, and cannot provide this interface without some runtime
overhead.
2019-09-10 20:12:30 +03:00
Nikolai Kochetov
e9e0bd82b9 Change number of aggregating streams. 2019-09-10 20:08:06 +03:00
Nikolai Kochetov
8dd8ab7d1f Use header in native format created in InterpreterSelectQuery. Fill missed columns in Native format. 2019-09-10 19:31:41 +03:00
chertus
02691f50ef make things wrong 2019-09-10 17:51:28 +03:00
chertus
1b313eedfa MergeJoin in progress 2019-09-09 22:43:37 +03:00
Nikolai Kochetov
c9cca3ba8b Merged with master 2019-09-09 16:20:30 +03:00
alesapin
27419c965e Merge with master 2019-09-09 14:13:36 +03:00
alexey-milovidov
8389200229
Merge pull request #6832 from CurtizJ/merging_input_function
Merging #5450 (table function input).
2019-09-07 20:16:45 +03:00
alexey-milovidov
25de2e12a2
Merge pull request #6399 from Enmk/replica_recovery_interval
Improvements for failover of Distributed queries
2019-09-07 03:21:30 +03:00
filimonov
526afd44ed Make SensitiveDataMasker a singleton. (#6810)
Among other things, it is used to filter logs, which are being written even after the global server context is deinitialized, so we can't keep masker there.
2019-09-06 20:48:27 +03:00
alexey-milovidov
c90dfc1e48
Merge pull request #6837 from filimonov/fix_some_pvs_reported_issues
Fix some pvs reported issues
2019-09-06 20:15:14 +03:00
Anton Popov
69da4f30b3
Merge branch 'master' into merging_input_function 2019-09-06 16:20:00 +03:00
filimonov
f505549b43
changed wrong pvs suppression code 2019-09-06 14:46:42 +02:00
Nikolai Kochetov
52305cefbc Merge branch 'merging-aggregated-processors' into processors-2 2019-09-06 15:21:17 +03:00
Nikolai Kochetov
d10b7d7a2b Added ConvertingAggregatedToChunksTransform. 2019-09-06 15:19:59 +03:00
alesapin
ea8e543b1a Add protocol version to cookies 2019-09-06 15:18:56 +03:00
alesapin
0c9a9dee1c Merge with master 2019-09-06 11:53:32 +03:00
alexey-milovidov
3d8ec8fb33
Merge pull request #6823 from yandex/fancyqlx-master
Merge #6167
2019-09-06 03:18:26 +03:00
alexey-milovidov
05a1a7ac71
Update InterpreterSelectQuery.cpp 2019-09-06 03:18:06 +03:00
alexey-milovidov
18dcb3753d
Merge pull request #6824 from 4ertus2/mjoin
Refactoring (ExpressionAnalyzer & SubqueryForSet)
2019-09-06 03:17:16 +03:00
Olga Khvostikova
f90642ce23
Merge pull request #6610 from CurtizJ/merging_with_ties_and_with_fill
WITH TIES modifier for LIMIT and WITH FILL modifier for ORDER BY. (continuation of #5069)
2019-09-05 22:45:48 +03:00
Mikhail Filimonov
b40204a360 PVS https://clickhouse-test-reports.s3.yandex.net/0/2cda8f1563e9b2d11f75c68db817c3f68ace1160/pvs_studio_report/pvs-studio-html-report/sources/InterpreterSelectQuery.cpp_24.html#ln430 2019-09-05 19:23:36 +02:00
Mikhail Filimonov
622ea38b21 PVS false positive https://clickhouse-test-reports.s3.yandex.net/0/2cda8f1563e9b2d11f75c68db817c3f68ace1160/pvs_studio_report/pvs-studio-html-report/sources/Context.cpp_21.html#ln1226 2019-09-05 18:59:15 +02:00
Mikhail Filimonov
cfb0431994 PVS https://clickhouse-test-reports.s3.yandex.net/0/2cda8f1563e9b2d11f75c68db817c3f68ace1160/pvs_studio_report/pvs-studio-html-report/sources/executeQuery.cpp_26.html#ln33 2019-09-05 18:57:13 +02:00
Vasily Nemkov
c2fc71b5e5 Post-PR fixes
Renamed settings, updated docs.
2019-09-05 13:35:36 +03:00
chertus
a395be3e91 minor changes 2019-09-04 19:37:05 +03:00
chertus
b854c945ad some more ExpressionAnalyzer refactoring 2019-09-04 19:20:02 +03:00
Nikolai Kochetov
3bd453985b Merge branch 'master' of https://github.com/fancyqlx/ClickHouse into fancyqlx-master 2019-09-04 18:48:12 +03:00
alesapin
3ffa9fa972 Resolve conflict 2019-09-04 15:44:12 +03:00
alesapin
8b6abab486 Merge branch 'master' into ObjatieGroba-feature_multiple_disks 2019-09-04 15:41:27 +03:00
CurtizJ
7accc09066 Merge branch 'palasonic-add-input-function' of https://github.com/palasonic1/ClickHouse into merging_input_function 2019-09-04 15:25:20 +03:00
chertus
904cfed046 better includes 2019-09-04 13:15:34 +03:00
Alexey Milovidov
6176041935 Fixed style 2019-09-04 02:08:46 +03:00
alexey-milovidov
b2e80b0cd9
Merge branch 'master' into query_masking 2019-09-03 22:58:15 +03:00
alexey-milovidov
1ae8150f28
Update Context.cpp 2019-09-03 22:53:59 +03:00
Artem Zuikov
0a998fddce
Merge pull request #6801 from 4ertus2/mjoin
Refactoring: wrap Join logic via AnalyzedJoin iface
2019-09-03 19:53:49 +03:00
alesapin
52442cf549 Add system stop moves query 2019-09-03 17:50:49 +03:00
chertus
bb3dedf1dc move Join object from ExpressionAction into AnalyzedJoin 2019-09-03 17:36:02 +03:00
alexey-milovidov
87e061d0e1
Merge pull request #6733 from 4ertus2/some
Add subquery_requires_alias setting (disabled by default)
2019-09-03 14:34:28 +03:00
alexey-milovidov
ab75e8c26d
Merge pull request #6205 from zhang2014/fix/some_mutation
fix some mutation bug
2019-09-03 14:33:20 +03:00
alesapin
8d76febe02 Add moves to part log 2019-09-03 14:32:25 +03:00
alexey-milovidov
7847de1947
Merge pull request #6629 from CurtizJ/read-in-order-2
Implement 'read in order' optimization with processors.
2019-09-03 14:21:19 +03:00
CurtizJ
22badef1a2 Merge remote-tracking branch 'upstream/master' into merging_with_ties_and_with_fill 2019-09-03 13:47:18 +03:00
Nikolai Kochetov
e55647eee9 Force add resize befor aggregating transform. 2019-09-03 13:14:13 +03:00
CurtizJ
6d821c4877 fix build 2019-09-03 13:07:31 +03:00
alesapin
e7308c1f21 Merge branch 'master' into ObjatieGroba-feature_multiple_disks 2019-09-03 11:02:32 +03:00
zhang2014
9c50c7c718 fix crash when touches all rows alter 2019-09-03 13:48:02 +08:00
CurtizJ
973b533377 Merge remote-tracking branch 'upstream/master' into read-in-order-2 2019-09-03 00:59:51 +03:00
chertus
fce1b47250 more JOIN refactoring: move logic out of ExpressionAnalyzer/ExpressionAction 2019-09-02 22:58:45 +03:00
Nikolai Kochetov
464595a548 Add allow_processors flag to executeQuery. 2019-09-02 18:19:01 +03:00
CurtizJ
de5e2b4d6b Merge remote-tracking branch 'upstream/master' into merging_with_ties_and_with_fill 2019-09-02 17:34:49 +03:00
CurtizJ
da11fb86b7 implement 'with fill' modifier with processors 2019-09-02 17:29:51 +03:00
Vasily Nemkov
f98c488834 Post-review fixes
* Actually using the replica recovery settings for cluster
* A bit of doc on DBMS_CONNECTION_POOL_WITH_FAILOVER_MAX_ERROR_COUNT
* StorageDistributedDirectoryMonitor using settings for ConnectionPoolWithFailover
* Using SettingSeconds instead of SettingUInt64 for replica_error_decrease_period
2019-09-02 17:26:25 +03:00
Nikolai Kochetov
bf0c0ed4f1 Merge branch 'master' into processors-2 2019-09-02 16:02:09 +03:00
chertus
bc95027cee better setting name: joined_subquery_requires_alias 2019-09-02 15:53:31 +03:00
chertus
2c0d569fa8 Merge branch 'master' into some 2019-09-02 15:32:24 +03:00
alesapin
e7ee9b7a67 Merge master 2019-09-02 11:46:00 +03:00
alexey-milovidov
2e86aece86
Merge pull request #6763 from yandex/add-os-thread-ids-in-system-tables
Add "os_thread_ids" column to system tables
2019-09-01 04:30:16 +03:00
alexey-milovidov
1dd28867b0
Merge pull request #6689 from yandex/merge_tree_settings_alter
Refactoring of immutable settings
2019-09-01 04:29:47 +03:00
Alexey Milovidov
cb79e2371e Add "os_thread_ids" column to system tables 2019-09-01 00:47:15 +03:00
alexey-milovidov
d8d2b623d2
Merge pull request #6759 from yandex/add-test-rwr-shard-deadlock
Added a test for possible deadlock in distributed queries
2019-08-31 18:51:48 +03:00
Alexey Milovidov
aac0b27daa Fixed possible deadlock in distributed queries 2019-08-31 15:18:14 +03:00
Alexey Milovidov
01035a9e78 Merge branch 'master' of github.com:yandex/ClickHouse into add-test-deadlock-rename-table 2019-08-31 13:46:24 +03:00
Alexey Milovidov
202673e3bd Avoid deadlock in multiple tables RENAME 2019-08-31 13:37:28 +03:00
Nikolai Kochetov
300dc80194 Update Aggregator interface. 2019-08-31 11:58:16 +03:00
Alexey Milovidov
2fd8f5c324 Removed code that I don't understand and that has no comments 2019-08-31 02:09:08 +03:00
alesapin
6f30338c08 Fixes 2019-08-30 21:31:35 +03:00
Nikolai Kochetov
18fff141d1 Update max_threads for processors. 2019-08-30 17:21:22 +03:00
alesapin
d7e54d3c14 Merge branch 'master' of github.com:yandex/ClickHouse into ObjatieGroba-feature_multiple_disks 2019-08-30 12:53:24 +03:00
Vitaly Baranov
da8f67123f Improve error handling in cache dictionaries:
allow using expired values while the source of a cache dictionary doesn't respond;
clone the source after an error to reset connections;
don't ask the source for a little time after error;
show the last exception in system.dictionaries for a cache dictionary too.
2019-08-30 12:50:38 +03:00
CurtizJ
048d3da9ab better types comparison and conversion in FillingBlockInputStream 2019-08-30 01:24:33 +03:00
chertus
3ad43daae3 Merge branch 'master' into some 2019-08-29 21:50:47 +03:00
chertus
d5cfbcf6e1 subquery_requires_alias setting (disabled by default) 2019-08-29 21:45:34 +03:00
CurtizJ
a6e43c4119 merging with master 2019-08-29 19:48:02 +03:00
alesapin
1813b96f82 Finally build, possible trash. 2019-08-29 19:17:47 +03:00
Ivan
5851316742
Don't interrupt copyData() used inside Kafka materialized views (#6597)
* Print better offsets on commit
* Stop consumption on the read buffer level
* Don't use cancellation in the middle of copyData()
* Add test
* Disable squashing stream for Kafka materialized views
* Commit last read message, since rdkafka auto-modifies offset
2019-08-29 18:36:07 +03:00
alesapin
dac55278ad Better comments 2019-08-29 14:15:56 +03:00
alesapin
67f9753775 Merge branch 'master' into bad_size_of_marks_skip_idx_bug 2019-08-29 11:07:56 +03:00
zhang2014
275c0d88b3 fix build failure 2019-08-29 12:54:09 +08:00
zhang2014
74c9eea657 fix test failure 2019-08-29 11:34:00 +08:00
zhang2014
3c7405bdb0 move test to integration & refer max_expanded_ast_elements 2019-08-29 11:31:22 +08:00
Ivan
b4339f266d
Make a better build scheme (#6500)
* Fix shared build
* Major default libs refactor
* Fix build with gcc_eh
* Link all libraries as a big group.
* Use global interface library as a group
* Build capnproto using our cmake
* Use only internal libunwind
2019-08-28 23:49:37 +03:00
Alexey Milovidov
48dce81e61 Minor modifications after #6413 2019-08-28 21:54:30 +03:00
alexey-milovidov
33311a9bf1
Merge branch 'master' into atomic_zookeeper2 2019-08-28 21:34:42 +03:00
alesapin
b4d98f6e13 Trying to fix vertical merge 2019-08-28 21:23:20 +03:00
alexey-milovidov
44dd3bd792
Merge pull request #6692 from yandex/remove-queue_max_wait_ms
Set default value of "queue_max_wait_ms" to zero, because current value makes no sense
2019-08-28 21:06:09 +03:00
alexey-milovidov
7b9b67fd71
Merge pull request #6695 from yandex/improve-table-locks
Avoid possible deadlock in TRUNCATE of Replicated table.
2019-08-28 21:05:26 +03:00
alexey-milovidov
6d2dca3242
Merge pull request #6705 from 4ertus2/bugs
JOINs with not nullable types and join_use_nulls=1
2019-08-28 21:05:16 +03:00
Nikolai Kochetov
d6e13cbb92 Update max_threads for processors. 2019-08-28 20:48:41 +03:00
Nikolai Kochetov
ca232cebfb Update max_threads for processors. 2019-08-28 20:30:48 +03:00
alexey-milovidov
e2b05f6f9c
Merge pull request #6700 from yandex/aku/shm-5417-formatting
Formatting changes for StringHashMap PR #5417.
2019-08-28 18:30:59 +03:00
Alexey Milovidov
b6a0dba2df Added a setting "connection_pool_max_wait_ms" 2019-08-28 18:27:26 +03:00
Alexey Milovidov
cced091881 Addition to prev. revision 2019-08-28 18:24:35 +03:00
Alexey Milovidov
d06e350312 Added setting "replace_running_query_max_wait_ms" 2019-08-28 18:20:22 +03:00
chertus
90d5410aaa join_use_nulls with not nullable types 2019-08-28 17:14:09 +03:00
Alexey Milovidov
8b973fd9f2 Merge branch 'improve-table-locks' of github.com:yandex/ClickHouse into improve-table-locks 2019-08-28 15:59:23 +03:00
Alexey Milovidov
625e128770 Merge branch 'master' into improve-table-locks 2019-08-28 15:41:30 +03:00
Alexander Kuzmenkov
0b5a7f5f4a Disable consecutive key optimization for UInt8/16 LowCardinality
columns.

A follow-up to #6298, this is as well a part of StringHashMap PR #5417
by Amos Bird.
2019-08-28 14:05:52 +03:00
Alexander Kuzmenkov
24a8755b82 Formatting changes for StringHashMap PR #5417. 2019-08-28 13:52:14 +03:00
Artem Zuikov
8fa4575a88
Merge pull request #6693 from 4ertus2/mjoin
Minor refactoring
2019-08-28 10:12:37 +03:00
Alexey Milovidov
c8798b2ffa Slightly improve table locks 2019-08-28 02:47:30 +03:00
Alexey Milovidov
e7cbd34a29 Improve table locks (incomplete) 2019-08-27 23:43:35 +03:00
Alexey Milovidov
285d66cee1 Improve table locks (incomplete) 2019-08-27 23:43:08 +03:00
chertus
5208a70203 one less place with changed nullability columns 2019-08-27 22:41:51 +03:00
Alexey Milovidov
25c53ccd9e Rename setting 2019-08-27 22:05:35 +03:00
Alexey Milovidov
b21fdff77e Merging #6678 2019-08-27 21:59:21 +03:00
Alexey Milovidov
5ca8f8d695 Merge branch 'master' of https://github.com/weiqxu/ClickHouse into weiqxu-master 2019-08-27 21:52:09 +03:00
Nikolai Kochetov
4cb52cebea Update max_threads for processors. 2019-08-27 21:37:28 +03:00
CurtizJ
50d870705c limit with ties for processors 2019-08-27 20:48:42 +03:00
CurtizJ
42633c801b Merge remote-tracking branch 'upstream/master' into merging_with_ties_and_with_fill 2019-08-27 17:11:57 +03:00