Commit Graph

780 Commits

Author SHA1 Message Date
Alexey Milovidov
db0fc6c9a6 Fix tests 2020-06-14 21:24:25 +03:00
Alexey Milovidov
394fb64a9c Better way of implementation 2020-06-14 20:42:11 +03:00
Alexander Tokmakov
6a439a5eb5 fixes 2020-06-14 19:39:06 +03:00
Alexander Tokmakov
5f9739fbf9 Merge branch 'master' into fork-potya/null_data_mods 2020-06-14 18:11:55 +03:00
alexey-milovidov
56b8d81ef6
Merge pull request #11651 from ClickHouse/empty-parameters-url
Skip empty URL parameters
2020-06-14 09:00:52 +03:00
Alexey Milovidov
44221139e9 Fix test 2020-06-14 07:35:50 +03:00
Alexey Milovidov
bba0140d8f Fix tests 2020-06-14 07:20:52 +03:00
Alexey Milovidov
fed6843e64 Fix style 2020-06-14 07:16:52 +03:00
Alexey Milovidov
4024840795 Add a test 2020-06-14 07:16:52 +03:00
Alexey Milovidov
ff3e5e1a2e Allow implicit conversion from String in IN, VALUES and comparison #11630 2020-06-14 07:16:52 +03:00
Alexey Milovidov
eec5abde07 Fix test 2020-06-14 07:16:23 +03:00
Alexey Milovidov
6c278fee61 Better exception message 2020-06-14 04:07:47 +03:00
Alexey Milovidov
2cd82a25f5 Remove trivial count query optimization if row-level security is set #11352 2020-06-13 23:59:20 +03:00
alesapin
5d3de747cd Merge remote-tracking branch 'origin/master' into consistent_metadata4 2020-06-13 11:50:27 +03:00
Alexey Milovidov
cfef7ba692 Whitespace 2020-06-13 04:35:49 +03:00
Azat Khuzhin
7f52b615e0 Fix bloom filters for String (data skipping indices)
bloom filter was broken for the first element, if all of the following
conditions satisfied:
- they are created on INSERT (in thie case bloom filter hashing uses
  offsets, in case of OPTIMIZE it does not, since it already has
  granulars).
- the record is not the first in the block
- the record is the first per index_granularity (do not confuse this
  with data skipping index GRANULARITY).
- type of the field for indexing is "String" (not FixedString)

Because in this case there was incorrect length and *data* for that string.
2020-06-12 22:46:40 +03:00
Alexey Milovidov
72257061d5 Avoid errors due to implicit int<->bool conversions when using ZK API 2020-06-12 18:09:12 +03:00
alesapin
0edf5ff7a2 Fix race condition 2020-06-12 17:32:47 +03:00
Azat Khuzhin
103eb17107 Force table creation on SYSTEM FLUSH LOGS (v2)
After this patch SYSTEM FLUSH LOGS will force system.*_log table
creatoins (only for enabled tables of course).

This will avoid such hacks like:

   set log_queries=1;
   select 1;
   system flush logs;

This is the second version of the patch, since first has a deadlock [1]
(reported by @alesapin). This version does not use separate lock and do
not issue CREATE TABLE from the query execution thread, instead it
activate flushing thread to do so, hence this should be the same as if
the table will be created during flush.

  [1]: https://gist.github.com/alesapin/d915d1deaa27d49aa31223daded02be2

Fixes: #11563
Cc: @alesapin
Cc: @nikitamikhaylov
2020-06-11 23:12:23 +03:00
Azat Khuzhin
7884c8ef2c Use lock_guard over unique_lock in SystemLog 2020-06-11 21:55:41 +03:00
Alexander Kuzmenkov
e354bbc78c
Merge pull request #11588 from ClickHouse/aku/async-log
Add system.asynchronous_metric_log
2020-06-11 16:10:35 +03:00
alesapin
5a9a63e9a1
Revert "Force table creation on SYSTEM FLUSH LOGS" 2020-06-11 13:22:24 +03:00
tavplubix
1777bd0273
Merge pull request #11467 from hexiaoting/showcreate
Add "SHOW CLUSTER(s)" queries support
2020-06-11 12:01:28 +03:00
alexey-milovidov
c7be0d6bc0
Merge pull request #11578 from ClickHouse/fix_10240
Fix query_id of http queries
2020-06-11 06:55:04 +03:00
alexey-milovidov
9c20afbc81
Merge pull request #11579 from ClickHouse/fix_11490
Fix segfault in SHOW CREATE TABLE
2020-06-11 06:54:47 +03:00
alexey-milovidov
9e688307cb
Merge pull request #11580 from ClickHouse/fix-bug-prewhere-in-subquery
Fix prewhere in subquery
2020-06-11 06:53:44 +03:00
Nikita Mikhaylov
425c20eeb8
Merge pull request #11563 from azat/SYSTEM-FLUSH-LOGS-force-table-creation
Force table creation on SYSTEM FLUSH LOGS
2020-06-11 02:03:34 +04:00
Alexander Kuzmenkov
a6648516f4 Add files; flush more often 2020-06-11 00:16:58 +03:00
Alexander Kuzmenkov
e4be52f35f Add system.asynchronous_metric_log 2020-06-10 22:17:54 +03:00
alexey-milovidov
123a017057
Merge pull request #11528 from azat/use_compact_format_in_distributed_parts_names-fix
Fix shard_num/replica_num for <node> (breaks use_compact_format_in_distributed_parts_names)
2020-06-10 22:02:51 +03:00
Nikita Mikhaylov
bf262a3b04
more lock_guard 2020-06-10 18:44:28 +03:00
Nikita Mikhaylov
8c19817575
lock_guard 2020-06-10 18:30:50 +03:00
Nikolai Kochetov
d4c8adbaff Fix sanitizeBlock 2020-06-10 18:06:37 +03:00
Alexander Tokmakov
08073903ed fix query_id of http queries 2020-06-10 17:24:42 +03:00
Alexander Tokmakov
9166ddea41 fix segfault in show create table 2020-06-10 15:53:12 +03:00
Azat Khuzhin
8a78cffe5c Force table creation on SYSTEM FLUSH LOGS 2020-06-09 21:11:08 +03:00
Nikolai Kochetov
595fc9eff6
Merge pull request #11440 from ClickHouse/add-remote-source
Add remote source
2020-06-09 19:27:28 +03:00
Ivan
47ad338cb2
Refactor CMake build files (#11390)
* Get rid of lib_name.cmake
* Refactor Boost and HyperScan libraries
* Refactor lz4
* Fix build with xxHash
2020-06-09 13:54:49 +03:00
hexiaoting
75075a7b2b Add DISTINCT keyword when show clusters 2020-06-09 10:39:37 +08:00
Azat Khuzhin
c35f5e9271 Fix shard_num/replica_num for <node> (breaks use_compact_format_in_distributed_parts_names)
In system.clusters it was 1/1 while in address into it was 0/0
2020-06-08 22:30:13 +03:00
Alexey Milovidov
138f3253ba Fix gcc build 2020-06-08 15:33:00 +03:00
Alexey Milovidov
58e513f59e Corrected implementation for the case without key 2020-06-08 07:23:56 +03:00
Alexey Milovidov
4216f2fe37 Merge branch 'master' into fix-aggregation-state-exception-safety-memory-leak 2020-06-08 06:31:20 +03:00
hexiaoting
71e43934b7 Fix rest errors found by style check 2020-06-08 10:29:53 +08:00
hexiaoting
75768413ad fix errors found by Style Check 2020-06-08 10:23:57 +08:00
alexey-milovidov
16f0e3a467
Merge pull request #11493 from ClickHouse/kuskarov-fix_history_bugs
Merging #11453 (save history in clickhouse-client after every query)
2020-06-08 02:13:20 +03:00
Alexey Milovidov
834f8426e0 Fix memory leak 2020-06-08 01:46:58 +03:00
Alexey Milovidov
f2cfb7d132 Whitespaces 2020-06-08 00:05:36 +03:00
Alexey Milovidov
df19db1509 Added a test for history in clickhouse-client 2020-06-07 20:29:34 +03:00
tavplubix
686c0539db
Merge pull request #11487 from ClickHouse/improve_dns_cache
Use DNSResolver to check if user is allowed to connect from an address
2020-06-07 19:55:03 +03:00
Alexander Tokmakov
0cf8015f4a use DNSResolver to check if user is allowed to connect 2020-06-07 00:02:29 +03:00
Alexey Milovidov
d3d02a67f4 Speed up build by removing old example programs 2020-06-06 19:19:16 +03:00
Anton Popov
5c42408add
Merge pull request #9113 from dimarub2000/group_by_in_order_optimization
[WIP] Optimization of GROUP BY with respect to table sorting key.
2020-06-06 14:25:59 +03:00
alexey-milovidov
050ef9eb54
Merge pull request #11455 from azat/INSERT-SELECT-FINAL-pipeline-stuck
Fix Pipeline stuck for INSERT SELECT FINAL
2020-06-06 12:36:07 +03:00
alexey-milovidov
e8a7fab81c
Merge pull request #11480 from 4ertus2/some
Refactoring: remove TableWithColumnNames
2020-06-06 12:33:16 +03:00
alexey-milovidov
937dd79880
Merge pull request #11477 from ClickHouse/aku/generate-random
generateRandom: check that all arguments are literals
2020-06-06 12:08:24 +03:00
Alexander Kuzmenkov
fafa953ee4 fixup 2020-06-06 04:23:21 +03:00
Artem Zuikov
1ee09a9f89 disable ColumnMatch::ColumnName logic 2020-06-06 02:14:18 +03:00
alexey-milovidov
5f99d887cc
Merge pull request #11443 from 4ertus2/strange
Rename setting
2020-06-06 01:45:21 +03:00
Artem Zuikov
fdba90dd12 Merge branch 'master' into some 2020-06-06 00:50:42 +03:00
Artem Zuikov
0f37304521 hotfix: save tmp container 2020-06-06 00:28:44 +03:00
Artem Zuikov
c58f9bd43d refactoring: remove TableWithColumnNames 2020-06-06 00:17:00 +03:00
Alexander Kuzmenkov
d17a435fb6
Merge pull request #11226 from ClickHouse/aku/merge-perf-events
Merge Perf events metrics #9545
2020-06-05 23:10:54 +03:00
Artem Zuikov
ecca78d855
fix trivial count with join (#11454) 2020-06-05 13:28:52 +03:00
Artem Zuikov
9717f3cfe5 make clang tidy happy 2020-06-05 13:27:54 +03:00
Alexander Kuzmenkov
eaaf005a03
Merge pull request #11410 from ClickHouse/aku/logical-error-synonyms
Remove assorted synonyms of LOGICAL_ERROR
2020-06-05 13:10:40 +03:00
Nikolai Kochetov
5fea34d0e1 Use Resize instead of Concat in InterpreterInsertQuery. 2020-06-05 12:30:16 +03:00
hexiaoting
d2052dd1d4 show clusters 2020-06-05 17:13:13 +08:00
Artem Zuikov
ab86ca2fb6 rename v2 2020-06-05 01:10:52 +03:00
Artem Zuikov
b66ad25841
IColumn::getDataType() (#11438) 2020-06-05 01:02:59 +03:00
Artem Zuikov
6d211bec19 fix trivial count with join 2020-06-05 01:01:40 +03:00
Artem Zuikov
24ee7346a9 rename setting 2020-06-04 17:31:57 +03:00
alesapin
b163052d1b
Merge pull request #11134 from GrigoryPervakov/custom-auth
Add default credentials and custom headers for s3 storage.
2020-06-04 16:46:01 +03:00
Nikolai Kochetov
f54f948162 Added DelayedSource. 2020-06-04 15:17:35 +03:00
Alexander Kuzmenkov
dacbe8e445
Update src/Interpreters/DatabaseCatalog.cpp 2020-06-04 14:06:07 +03:00
Alexander Kuzmenkov
13762854c6
Update src/Interpreters/DatabaseCatalog.cpp 2020-06-04 14:05:34 +03:00
Artem Zuikov
6cdeb060fb
Fix JOIN over LC and Nullable in key (#11414) 2020-06-04 13:07:22 +03:00
Alexey Milovidov
a0fd9b021a Fix MSan failure in MergeTree 2020-06-04 01:11:06 +03:00
Alexander Kuzmenkov
91b1d381bb fixup 2020-06-03 16:34:36 +03:00
Alexander Kuzmenkov
07e4bb7050 Remove assorted synonyms of LOGICAL_ERROR.
We don't need any special handling for them on the client, and, on the
contrary, have to handle them as logical errors in tests.
2020-06-03 16:18:42 +03:00
Alexander Kuzmenkov
3bf9cec63b Merge remote-tracking branch 'origin/master' into HEAD 2020-06-03 14:49:49 +03:00
Artem Zuikov
1b91dd8ea0
better error for USING key (#11404) 2020-06-03 13:50:15 +03:00
Ruslan
7757c9ec57
Remove arithmetic operations from aggregation functions (#10047) 2020-06-03 13:28:30 +03:00
Alexander Kuzmenkov
c7d9094a7a
Merge pull request #11259 from ClickHouse/consistent_metadata3
More consistent metadata for secondary indices
2020-06-03 12:23:21 +03:00
Ilya Yatsishin
4b2e92bb40
Merge pull request #11389 from 4ertus2/bugs
Fix logical error in joinGet()
2020-06-03 07:49:03 +03:00
Artem Zuikov
7e7aea0ddb better errors for joinGet() 2020-06-02 23:26:41 +03:00
Pervakov Grigorii
bc9381406f Add default credentials and custom headers for s3 table functions. 2020-06-02 20:48:49 +03:00
alexey-milovidov
9b07989954
Merge pull request #11348 from ClickHouse/lazy-database-segfault-2
Fix potential segfault when using Lazy database.
2020-06-02 16:37:23 +03:00
Nikolai Kochetov
9a283de670
Merge pull request #11339 from ClickHouse/remove-experimantal-use-processors-flag-5
Remove some streams.
2020-06-02 14:46:02 +03:00
alesapin
1ab3047201 Merge branch 'master' into consistent_metadata3 2020-06-02 10:37:12 +03:00
Nikolai Kochetov
45a1db7a80 Try fix tets. 2020-06-02 08:16:45 +03:00
Alexey Milovidov
a6bf4b5d70 Fix error with Lazy database 2020-06-02 05:06:16 +03:00
Alexey Milovidov
bdfa552844 Fix nullptr dereference in SYSTEM query and Lazy database 2020-06-02 04:53:32 +03:00
Alexander Kuzmenkov
03d8bf9242 Merge remote-tracking branch 'origin/master' into HEAD 2020-06-01 20:15:25 +03:00
Nikolai Kochetov
53d12f5ab8 Try fix build. 2020-06-01 20:06:21 +03:00
Nikolai Kochetov
325393d340 Try fix build. 2020-06-01 19:58:36 +03:00
Nikolai Kochetov
3a0acb00c1 Remove some streams. 2020-06-01 19:31:06 +03:00
alexey-milovidov
19c6e0e5ae
Merge pull request #11307 from ClickHouse/remove-system-tables-lazy-load
Remove "system_tables_lazy_load" option
2020-06-01 16:26:23 +03:00
alesapin
254d55f2ab Better method name 2020-06-01 15:02:36 +03:00
alesapin
663e92b1c5 Rename to methods 2020-06-01 14:29:11 +03:00
alesapin
3847ea892d Merge branch 'master' into consistent_metadata3 2020-06-01 13:17:59 +03:00
Artem Zuikov
9028a25f3c
more types in ASOF JOIN (#11301) 2020-06-01 12:38:46 +03:00
alexey-milovidov
9984e989c1
Merge pull request #11317 from ClickHouse/logger-fmt-2
Preparation for structured logging
2020-06-01 00:11:29 +03:00
alexey-milovidov
a8f5b10f15
Merge pull request #10621 from azat/enable_optimize_predicate_expression-order
Fix predicates optimization for distributed queries with HAVING
2020-05-31 18:55:35 +03:00
Alexey Milovidov
87cf123ef8 Merge branch 'master' into remove-system-tables-lazy-load 2020-05-31 18:06:08 +03:00
Alexey Milovidov
85537d7b94 Miscellaneous changes for SystemLogs 2020-05-31 17:38:02 +03:00
alexey-milovidov
bebc6f82fc
Merge pull request #10678 from livace/add_geo_types
Add geo data types Point and Polygon
2020-05-31 17:25:15 +03:00
alexey-milovidov
97d9f218af
Merge pull request #11296 from ClickHouse/fix-false-too-slow
Fix bug with Throttler and query speed estimation
2020-05-31 14:18:29 +03:00
Alexey Milovidov
25f941020b Remove namespace pollution 2020-05-31 00:57:37 +03:00
Alexey Milovidov
5aff138956 Preparation for structured logging 2020-05-31 00:35:52 +03:00
Dmitry
4b0d32f026 Merge branch 'master' of github.com:yandex/ClickHouse into group_by_in_order_optimization 2020-05-31 00:21:02 +03:00
alexey-milovidov
3eea042d16
Merge pull request #11243 from ClickHouse/remove-experimental-use-processors-flag-4
Remove some code.
2020-05-30 21:05:14 +03:00
Alexey Milovidov
421a62e978 Merge branch 'master' into fix-false-too-slow 2020-05-30 19:36:55 +03:00
Alexey Ilyukhov
3b78b010e5 Add empty line 2020-05-30 18:30:09 +03:00
Alexey Ilyukhov
b84c8fcbd8 Add allow_experimental_geo_types; add test 2020-05-30 18:26:19 +03:00
Alexey Milovidov
496fed5ed3 Remove "system_tables_lazy_load" option 2020-05-30 17:24:09 +03:00
Alexey Milovidov
e4a329a47f Checking max execution speed on all nodes #5732 2020-05-29 23:37:37 +03:00
tavplubix
a4e40fb5f2
Merge pull request #11269 from ClickHouse/add_context_to_idatabase_methods
Add context to IDatabase methods
2020-05-29 21:15:35 +03:00
alexey-milovidov
1abaca5174
Merge pull request #11276 from ClickHouse/fix-constraints-and-insert-performance
Fix constraints for DEFAULT fields; fix constraints for temporary tables; improve performance of INSERT for small blocks.
2020-05-29 20:04:59 +03:00
Anton Popov
e6a9a33010
Merge pull request #11183 from ClickHouse/consistent_metadata2
Refactor TTLs metadata (move them to IStorage).
2020-05-29 20:00:11 +03:00
Nikolai Kochetov
f7e0e87c7d Try fix tests. 2020-05-29 19:35:09 +03:00
alexey-milovidov
304c6a1ee3
Merge pull request #11278 from vitlibar/fix-crash-set-default-role-with-wrong-args
Fix crash when SET DEFAULT ROLE is called with wrong arguments.
2020-05-29 16:24:42 +03:00
Alexander Kuzmenkov
6e3bbf83e3 thread-local perf events 2020-05-29 16:04:32 +03:00
Nikolai Kochetov
bd814d83de Try fix tests. 2020-05-29 16:04:03 +03:00
alesapin
748e8fbfc3 Merge with master 2020-05-29 14:03:11 +03:00
alesapin
0170250c5e Merge branch 'master' into consistent_metadata2 2020-05-29 13:48:09 +03:00
Nikolai Kochetov
bbb57b7789 Try fix tests. 2020-05-29 13:31:19 +03:00
Vitaly Baranov
2d12b4d3ac Fix crash when SET DEFAULT ROLE is called with wrong arguments. 2020-05-29 09:54:27 +03:00
Alexey Milovidov
23d7947549 Fix constraints for DEFAULT fields; fix constraints for temporary tables; improve performance of INSERT for small blocks 2020-05-29 05:08:48 +03:00
Alexander Tokmakov
c071e0a473 add context to DatabaseCatalog methods 2020-05-29 02:01:18 +03:00
Alexander Tokmakov
3cff070f89 add context to IDatabase methods 2020-05-28 23:10:45 +03:00
Vitaly Baranov
d7cc703233
Merge pull request #11080 from vitlibar/add-authentication-type-to-system-users
Show authentication type in system.users table
2020-05-28 20:20:41 +03:00
alesapin
860dc2c814 Merge with consistent_metadata2 2020-05-28 19:45:51 +03:00
Nikolai Kochetov
534e55f5b5 try fix tests. 2020-05-28 19:01:12 +03:00
alesapin
61aff798d3 Compileable code 2020-05-28 18:33:44 +03:00
Nikolai Kochetov
ea3f638b30 Try fix tests. 2020-05-28 17:11:36 +03:00
Nikolai Kochetov
28cc6d9c6b Try fix tests. 2020-05-28 17:03:32 +03:00
Nikolai Kochetov
030aa6eac4 Fix build. 2020-05-28 16:57:01 +03:00
alesapin
f5e5290c0a Better naming 2020-05-28 16:09:03 +03:00
alesapin
26a9829e04 Indices description as vector 2020-05-28 15:47:17 +03:00
alesapin
52ca6b2051 I'm able to build it 2020-05-28 15:37:05 +03:00
Nikolai Kochetov
557e531ff3 Fix tests. 2020-05-28 15:06:31 +03:00
Nikolai Kochetov
2a9bcfbcd1 Fix build. 2020-05-28 14:00:12 +03:00
Nikolai Kochetov
da0052858d Fix build. 2020-05-28 13:57:04 +03:00
Nikolai Kochetov
6efa4d1d4f Fix style. 2020-05-28 13:41:59 +03:00
Nikolai Kochetov
5572f6c276 Fix style. 2020-05-28 12:07:40 +03:00
Nikolai Kochetov
1fa795988f Remove some code. 2020-05-28 11:24:59 +03:00
Vitaly Baranov
98172deffc Show authentication type in table system.users and while executing SHOW CREATE USER query. 2020-05-28 08:34:10 +03:00
Nikolai Kochetov
242ba74872
Merge pull request #11148 from ClickHouse/remove-experimental-use-processors-flag-3
Insert select with QueryPipeline
2020-05-28 07:47:59 +03:00
Nikolai Kochetov
2dcee3db5c Merge branch 'master' into remove-experimental-use-processors-flag-3 2020-05-27 21:25:34 +03:00
Nikolai Kochetov
e93882c977 Insert select using PipelineExecutor. 2020-05-27 21:20:26 +03:00
Alexander Kuzmenkov
db84f0e892 Merge remote-tracking branch 'origin/master' into HEAD 2020-05-27 16:30:13 +03:00
potya
df13694a03 Fix style errors 2020-05-27 15:32:39 +03:00
potya
d5840688a1 Fix style errors 2020-05-27 15:22:12 +03:00
Nikolai Sorokin
6585571ee2 Fix bug 2020-05-27 12:53:15 +03:00
Nikolai Sorokin
c6541b1dad Up test id; Fix clang build 2020-05-27 12:53:15 +03:00
Nikolai Sorokin
66496dc7e3 Fix trailing spaces 2020-05-27 12:53:15 +03:00
Nikolai Sorokin
61974e0047 TTL Expressions WHERE and GROUP BY draft 2020-05-27 12:53:15 +03:00
alesapin
c7cda399c7 Merge branch 'master' into consistent_metadata2 2020-05-27 12:51:56 +03:00
Dmitry
38c585f867 Merge branch 'master' of github.com:yandex/ClickHouse into group_by_in_order_optimization 2020-05-26 21:27:50 +03:00
Alexander Kuzmenkov
83aaea7b0f Merge remote-tracking branch 'origin/master' into HEAD 2020-05-26 18:29:42 +03:00
Alexander Kuzmenkov
4b1bb43543
Merge pull request #11076 from ClickHouse/aku/join-error-messages
Better error messages about joins
2020-05-26 09:09:59 +03:00
Alexander Kuzmenkov
9d25ae22b5 Merge remote-tracking branch 'origin/master' into HEAD 2020-05-26 09:07:01 +03:00
Alexander Kuzmenkov
7142e68d7a fixup 2020-05-26 08:54:04 +03:00
Nikita Mikhaylov
507d98b24b
Merge pull request #11006 from nikitamikhaylov/MorozovVasily-UpdatePermutation
Merging IColumn::updatePermutation
2020-05-26 01:42:41 +04:00
potya
1fbcdbb58a Fix error 2020-05-25 22:09:14 +03:00
potya
c9b1d6a6cc Merge remote-tracking branch 'origin/null_data_mods' into null_data_mods
# Conflicts:
#	src/Interpreters/InterpreterCreateQuery.cpp
2020-05-25 22:03:24 +03:00
potya
2974d81b2e Fix erros and add test 2020-05-25 21:58:30 +03:00
alesapin
d7c59bb4aa Merge branch 'master' into consistent_metadata2 2020-05-25 20:23:52 +03:00
alesapin
c3a6571036 Compilable code 2020-05-25 20:22:20 +03:00
Nikita Mikhaylov
b48deb91ac comments and styles 2020-05-25 17:33:31 +03:00
Nikita Mikhaylov
b7adfc7c07 Merge branch 'master' of github.com:ClickHouse/ClickHouse into MorozovVasily-UpdatePermutation 2020-05-25 17:26:30 +03:00
Artem Zuikov
04322b7b87 remove stale unit-test 2020-05-25 15:06:14 +03:00
potya
70fac9c068 Fix problems 2020-05-25 14:22:52 +03:00
potya
1ae82df3c0 at start 2020-05-25 14:20:33 +03:00
Nikolai Kochetov
c83014bc76
Merge pull request #11114 from azat/max_threads-simple-query-optimization-fix
Do not reserve extra threads after max threads optimization for simple queries
2020-05-25 14:05:46 +03:00
alesapin
6281dd6893
Merge pull request #11115 from ClickHouse/consistent_metadata
Refactoring in storage metadata (more consistent keys)
2020-05-25 13:09:56 +03:00
Alexander Kuzmenkov
8d5bbed2de Merge remote-tracking branch 'origin/master' into HEAD 2020-05-25 06:44:11 +03:00
Alexander Kuzmenkov
f1fb7245e5 Merge remote-tracking branch 'origin/master' into HEAD 2020-05-25 06:21:27 +03:00
Alexander Kuzmenkov
09129a6d21 Function for printing array of Asts 2020-05-25 06:19:46 +03:00
Alexey Milovidov
bff624e2ef Fix style 2020-05-24 01:30:43 +03:00
Alexey Milovidov
7e1813825b Return old names of macros 2020-05-24 01:24:01 +03:00
Alexey Milovidov
af2a59e49b Progress on task 2020-05-24 00:50:34 +03:00
Alexey Milovidov
d853bc39c5 Apply all transformations again 2020-05-24 00:41:48 +03:00
Alexey Milovidov
c87fb91532 Progress on task 2020-05-24 00:41:35 +03:00
Alexey Milovidov
93626701b8 Apply all transformations again 2020-05-24 00:27:27 +03:00
Alexey Milovidov
ce0619dabf Progress on task 2020-05-24 00:26:45 +03:00
Alexey Milovidov
bab24879e9 Progress on task 2020-05-24 00:16:05 +03:00
Alexey Milovidov
d2621fee30 Progress on task 2020-05-23 23:57:48 +03:00
Alexey Milovidov
cd6d3c7509 Progress on task 2020-05-23 22:55:06 +03:00
Alexey Milovidov
d5b7883451 find {base,src,programs} -name '*.h' -or -name '*.cpp' | xargs grep -l -P 'LOG_[^\_(]+\([^,]+, "[^"]+" << [^<]+ << "[^"]+" << [^<]+ << "[^"]+" << [^<]+ << "[^"]+"\);' | xargs sed -i -r -e 's/(LOG_[^\_(]+)\(([^,]+), "([^"]+)" << ([^<]+) << "([^"]+)" << ([^<]+) << "([^"]+)" << ([^<]+) << "([^"]+)"\);/\1_FORMATTED(\2, "\3{}\5{}\7{}\9", \4, \6, \8);/' 2020-05-23 22:41:08 +03:00
Alexey Milovidov
7e2fb9ad65 Apply all transformations again 2020-05-23 22:38:30 +03:00
Alexey Milovidov
eacff92d0e Progress on task 2020-05-23 22:35:08 +03:00
Alexey Milovidov
29762240de Remove duplicate whitespaces (preparation) 2020-05-23 22:31:54 +03:00
Alexey Milovidov
7fed65cbe2 Remove duplicate whitespaces (preparation) 2020-05-23 22:14:58 +03:00
Alexey Milovidov
ab0562a574 Make all LOG in single line (preparation) 2020-05-23 22:05:41 +03:00
Alexey Milovidov
9d2a0d2dd7 Apply all transformations again 2020-05-23 21:59:49 +03:00
Alexey Milovidov
a2ad11897f Remove duplicate whitespaces (preparation) 2020-05-23 21:53:58 +03:00
Alexey Milovidov
1f13515a65 Make all LOG in single line (preparation) 2020-05-23 21:31:37 +03:00
Alexey Milovidov
45b6abdfee Progress on task 2020-05-23 21:22:40 +03:00
Alexey Milovidov
9d24908e53 Progress on task 2020-05-23 20:52:11 +03:00
Azat Khuzhin
aa656f95dd Fix compilation on osx (where UInt64 and size_t is different) 2020-05-23 20:28:40 +03:00
Alexey Milovidov
d6bc4d2bd0 find {base,src,programs} -name '*.h' -or -name '*.cpp' | xargs grep -l -P 'LOG_\w+\([^,]+, [^<]+ << "[^"]+" << [^<]+\);' | xargs sed -i -r -e 's/(LOG_\w+)\(([^,]+), ([^<]+) << "([^"]+)" << ([^<]+)\);/\1_FORMATTED(\2, "{}\4{}", \3, \5);/' 2020-05-23 20:14:57 +03:00
Alexey Milovidov
7bc2b6bbbc find {base,src,programs} -name '*.h' -or -name '*.cpp' | xargs grep -l -P 'LOG_\w+\([^,]+, "[^"]+" \+ [^+]+ \+ "[^"]+" \+ [^+]+\);' | xargs sed -i -r -e 's/(LOG_\w+)\(([^,]+), "([^"]+)" \+ ([^+]+) \+ "([^"]+)" \+ ([^+]+)\);/\1_FORMATTED(\2, "\3{}\5{}", \4, \6);/' 2020-05-23 20:10:45 +03:00
Alexey Milovidov
241f8c5431 find {base,src,programs} -name '*.h' -or -name '*.cpp' | xargs grep -l -P 'LOG_\w+\([^,]+, "[^"]+" \+ [^+]+ \+ "[^"]+"\);' | xargs sed -i -r -e 's/(LOG_\w+)\(([^,]+), "([^"]+)" \+ ([^+]+) \+ "([^"]+)"\);/\1_FORMATTED(\2, "\3{}\5", \4);/' 2020-05-23 20:10:21 +03:00
Alexey Milovidov
f69cbdcbfc find {base,src,programs} -name '*.h' -or -name '*.cpp' | xargs grep -l -P 'LOG_\w+\([^,]+, "[^"]+" \+ [^+]+\);' | xargs sed -i -r -e 's/(LOG_\w+)\(([^,]+), "([^"]+)" \+ ([^+]+)\);/\1_FORMATTED(\2, "\3{}", \4);/' 2020-05-23 20:09:37 +03:00
Alexey Milovidov
533f86278a find {base,src,programs} -name '*.h' -or -name '*.cpp' | xargs grep -l -P 'LOG_\w+\([^,]+, "[^"]+" << [^<]+ << "[^"]+" << [^<]+ << "[^"]+"\);' | xargs sed -i -r -e 's/(LOG_\w+)\(([^,]+), "([^"]+)" << ([^<]+) << "([^"]+)" << ([^<]+) << "([^"]+)"\);/\1_FORMATTED(\2, "\3{}\5{}\7", \4, \6);/' 2020-05-23 20:00:41 +03:00
Alexey Milovidov
8042e5febe find {base,src,programs} -name '*.h' -or -name '*.cpp' | xargs grep -l -P 'LOG_\w+\([^,]+, "[^"]+" << [^<]+ << "[^"]+" << [^<]+\);' | xargs sed -i -r -e 's/(LOG_\w+)\(([^,]+), "([^"]+)" << ([^<]+) << "([^"]+)" << ([^<]+)\);/\1_FORMATTED(\2, "\3{}\5{}", \4, \6);/' 2020-05-23 19:58:15 +03:00
Alexey Milovidov
e391b77d81 find {base,src,programs} -name '*.h' -or -name '*.cpp' | xargs grep -l -P 'LOG_\w+\([^,]+, "[^"]+" << [^<]+ << "[^"]+"\);' | xargs sed -i -r -e 's/(LOG_\w+)\(([^,]+), "([^"]+)" << ([^<]+) << "([^"]+)"\);/\1_FORMATTED(\2, "\3{}\5", \4);/' 2020-05-23 19:56:05 +03:00
Alexey Milovidov
ee4ffbc332 find {base,src,programs} -name '*.h' -or -name '*.cpp' | xargs grep -l -P 'LOG_\w+\([^,]+, "[^"]+" << [^<]+\);' | xargs sed -i -r -e 's/(LOG_\w+)\(([^,]+), "([^"]+)" << ([^<]+)\);/\1_FORMATTED(\2, "\3{}", \4);/' 2020-05-23 19:47:56 +03:00
Alexey Milovidov
8d2e80a5e2 find {base,src,programs} -name '*.h' -or -name '*.cpp' | xargs grep -l -P 'LOG_\w+\([^,]+, "[^"]+"\)' | xargs sed -i -r -e 's/(LOG_\w+)\(([^,]+, "[^"]+")\)/\1_FORMATTED(\2)/' 2020-05-23 19:42:39 +03:00
tavplubix
6ece9649f1
Merge pull request #11151 from naorlov/CLICKHOUSE-7224
Add `FailedQuery`, `FailedSelectQuery` and `FailedInsertQuery`
2020-05-23 18:47:44 +03:00
potya
bee14177cd Fix NOT nULL modifier 2020-05-23 17:32:47 +03:00
Azat Khuzhin
0e12edb895 Fix max_threads simple query optimization for SELECT with subqueries
Fixes: 01245_limit_infinite_sources
2020-05-23 15:14:27 +03:00
Azat Khuzhin
d4804e070f Do not reserve extra threads after max threads optimization for simple queries
Before this patch pipeline.setMaxThreads() was called with 0 (since
streams.size() == 0, while pipes.size() == 1), which leads that
pipeline.getMaxThreads() returns max_streams.

While this threads were not used, they were reserved, which should not
happens either.
2020-05-23 13:19:09 +03:00
Nikita Orlov
09255b7c46
issue-7224 Codestyle changes 2020-05-23 02:37:14 +03:00
Nikita Orlov
dffd15f643
issue-7224 Add failed Insert and Select query counters to ProfileEvents 2020-05-23 01:00:15 +03:00
Azat Khuzhin
6a9ec1396a Access aggregate keys by names over indexes
Relax this to allow accepting aggregate keys in different order (typical
use case is distributed queries, where the initiator server will do
final merge).
2020-05-23 00:36:30 +03:00
Azat Khuzhin
1f45c4302a Drop check for getPositionByName() (it already has it) in ExpressionActions 2020-05-23 00:36:30 +03:00
Azat Khuzhin
6d40c1ea2c Preserve order of expressions during predicates optimization (enable_optimize_predicate_expression)
Before this patch enable_optimize_predicate_expression changes the
order *every* time, so:
  foo AND bar -> bar AND foo

And this causes troubles for distributed queries, since query on shard
will have different order of expressions with the initiating server.
2020-05-23 00:36:30 +03:00
alesapin
cd83ebc599
Merge pull request #11106 from ClickHouse/fix_deadlock_system_logs_startup
Fix deadlock in system tables during server startup
2020-05-22 20:53:07 +03:00
alesapin
f026fa7de1 Rename PartDestinationType to DataDestionationType, because there is no part-specific information 2020-05-22 16:29:33 +03:00
alexey-milovidov
10fd2dd17d
Merge pull request #11118 from ClickHouse/aku/trace-log-overflow-followup
A follow-up for trace log overflow in perftests
2020-05-22 14:29:11 +03:00
alesapin
70fe119426 Add clear names 2020-05-22 13:33:57 +03:00
alesapin
98ffefd90c Fix bug with return type 2020-05-22 13:09:24 +03:00
Nikolai Kochetov
f7456f8320
Merge pull request #11004 from ClickHouse/remove-experimental-use-processors-flag-2
Remove allow_processors flag from executeQuery()
2020-05-22 10:47:15 +03:00
Dmitry
47778c0259 Merge branch 'master' of github.com:yandex/ClickHouse into group_by_in_order_optimization 2020-05-21 23:45:12 +03:00
Alexander Kuzmenkov
087d8ab020 A follow-up for trace log overflow in perftests
The start was in https://github.com/ClickHouse/ClickHouse/pull/11026
It turned out that the problem was due to the incorrect mutate()
implementation that lead to quadratic amount of column copying. This
problem has since been fixed.

Remove the excessively verbose logging, and also change appendToBlock of
LogElement's to accept mutable columns instead of accepting a block and
mutating it on each call. It looks wasteful, even though it is almost a
noop.
2020-05-21 23:40:23 +03:00
Dmitry
ee22a3ad30 Adding Info in FinalizingSimpleTransform 2020-05-21 23:34:53 +03:00
alesapin
59b3bc0c05
Merge branch 'master' into fix_deadlock_system_logs_startup 2020-05-21 22:57:52 +03:00
alesapin
37fa26971e
boop ci 2020-05-21 21:49:31 +03:00
alesapin
87eab514fb Merge branch 'master' into consistent_metadata 2020-05-21 18:54:52 +03:00
alesapin
c036af0261 Fix deadlock after clickhouse-server update (with changes in one of system log tables structure) during startup between concurrent merge and table rename. 2020-05-21 17:11:56 +03:00
Azat Khuzhin
d93b9a57f6 Forward declaration for Context as much as possible.
Now after changing Context.h 488 modules will be recompiled instead of 582.
2020-05-21 01:53:18 +03:00
Alexander Kuzmenkov
50df893dc6 Assert that allocator & container are consistent wrt. inline memory
There are lots of places where HashTable is used with
AllocatorWithStackMemory, but the size of allocator inline memory is set
incorrectly, and it's less than the initial HashTable buffer size.
Because of this, HashTable is always allocated on the heap, and the
inline memory becomes a useless dead weight.

For PODArray, we have previously added a helper template that makes sure
these values are in sync, so there was only one such discrepancy left,
in the unit test.
2020-05-20 22:37:13 +03:00
Alexander Kuzmenkov
9e410444e7 Better error messages about joins 2020-05-20 21:58:20 +03:00
Andrey Skobtsov
4816abed28 Settings for measuring only particular metrics via perf events 2020-05-20 21:25:49 +03:00
potya
8a9064cef2 at start 2020-05-20 21:23:35 +03:00
alexey-milovidov
07924f0ae1
Merge pull request #11029 from azat/system_tables_lazy_load
Disable system_tables_lazy_load by default
2020-05-20 21:15:09 +03:00
alesapin
616902a995 Sorting and primary key (broken) 2020-05-20 21:11:38 +03:00
alesapin
8bc527eecd Compile partition key 2020-05-20 15:16:55 +03:00
Vitaly Baranov
06d18a4378
Merge pull request #11050 from vitlibar/amosbird_betterdictget
dictGet with table name
2020-05-20 14:18:24 +03:00
Artem Zuikov
9b38324028
fix JOIN with PREWHERE with second analyze() (#11051) 2020-05-20 12:29:23 +03:00
potya
d8bb98bbcf Add NULL and NOY NULL modifiers for data types in create query 2020-05-20 04:22:32 +03:00
Vitaly Baranov
57bd7afc03 Fix passing dictionary's name to dictGet() with alias. 2020-05-19 21:17:29 +03:00
Amos Bird
ce3c53a00a dictGet* with table name 2020-05-19 20:33:45 +03:00
Nikolai Kochetov
6109e87aed Try fix compatibility. 2020-05-19 18:40:15 +03:00
Alexander Kuzmenkov
ef6f386ee6
Merge pull request #11026 from ClickHouse/aku/trace-log
Add more logs to debug trace_log overflow
2020-05-19 17:56:06 +03:00
Alexander Kuzmenkov
838b3e9533 fixup 2020-05-19 17:55:27 +03:00
Nikolai Kochetov
b0d9552e1e Try fix compatibility. 2020-05-19 17:06:33 +03:00