Nikolai Kochetov
bb24a494ca
Fix preferch for LowCardinality.
2021-12-22 15:26:16 +03:00
kssenii
65c5334bb0
Safer
2021-12-22 14:22:14 +03:00
Maksim Kita
60d16afde7
Merge pull request #33027 from ClickHouse/merge-33023
...
Merge #33023
2021-12-22 13:44:14 +03:00
kssenii
060d3228e9
Fix
2021-12-22 13:43:21 +03:00
Maksim Kita
5d4b0f8f1a
Merge pull request #33026 from ClickHouse/remove-old-code-config-processor
...
Remove obsolete code from ConfigProcessor.
2021-12-22 13:34:53 +03:00
Maksim Kita
3e388db839
Dictionaries fix Date32 attribute underlying type
2021-12-22 13:21:59 +03:00
kssenii
d8ed4db6d4
Fix
2021-12-22 11:42:23 +03:00
zzsmdfj
039afc5cfe
#15182_MaterializeMySQL_support_bit_type-improve bit2Uint64 function
2021-12-22 16:17:18 +08:00
Stig Bakken
1cc70ad524
Remove the possibility of adding columns with table overrides
...
(except ALIAS columns)
Supporting this properly requires more comprehensive changes.
2021-12-22 08:20:14 +01:00
Kseniia Sumarokova
5ae2f0028f
Merge pull request #32961 from kssenii/fix-positional-args
...
Fix for positional args
2021-12-22 09:41:55 +03:00
Kseniia Sumarokova
484a4d62dd
Merge pull request #32835 from kssenii/fising-s3
...
Fix optimization with lazy seek for async reads from remote fs
2021-12-22 09:38:23 +03:00
Boris Kuschel
c62d9e2f2d
Out of Bounds Column Index
...
Signed-off-by: Boris Kuschel <Boris.Kuschel@ibm.com>
2021-12-21 22:43:47 -05:00
Meena-Renganathan
91036e729c
Fixed the indentation
...
Signed-off-by: Meena-Renganathan <Meena.Renganathan@ibm.com>
2021-12-21 16:07:24 -08:00
Boris Kuschel
c452b3fad9
Modifed the code to handle the sysconf() fialure
...
Signed-off-by: Boris Kuschel <Boris.Kuschel@ibm.com>
2021-12-21 18:33:00 -05:00
Alexey Milovidov
7b48cb813e
Merge branch 'Issue129' of github.com:DevTeamBK/ClickHouse into merge-33023
2021-12-22 02:17:00 +03:00
Alexey Milovidov
088d14b885
Remove obsolete code from ConfigProcessor.
2021-12-22 02:13:31 +03:00
Boris Kuschel
68de95afc9
Native Format Parsing - Integer Overflow Resizing Arrays
...
Signed-off-by: Boris Kuschel <Boris.Kuschel@ibm.com>
2021-12-21 18:10:51 -05:00
Dmitry Novik
38c1e81752
fixup
2021-12-21 22:00:08 +03:00
kssenii
de70a57700
Better
2021-12-21 21:48:25 +03:00
benbiti
81a7a393c8
fix unix timestamp convert, fractional reversed
2021-12-22 01:32:16 +08:00
Dmitry Novik
56917ca0ff
Fix WriteBuffer initialization
2021-12-21 18:49:20 +03:00
Amos Bird
f00cc3b944
optimize single part projection materialization
2021-12-21 22:39:06 +08:00
alesapin
084a1b5ac2
Merge pull request #32988 from JackyWoo/keeper_handler_remove_operation_when_response_sent
...
keeper handler should remove operation when response sent
2021-12-21 17:25:40 +03:00
mergify[bot]
7da6d8b310
Merge branch 'master' into fix_IP_conversion
2021-12-21 12:16:05 +00:00
Kseniia Sumarokova
de7a5dd1e6
Update ExpressionListParsers.cpp
2021-12-21 12:39:31 +03:00
alesapin
754785fee5
Better container
2021-12-21 11:07:24 +03:00
kssenii
ebcb66a361
Fix
2021-12-21 10:58:02 +03:00
mergify[bot]
7cf7c5d247
Merge branch 'master' into keeper_handler_remove_operation_when_response_sent
2021-12-21 07:55:19 +00:00
mergify[bot]
649226853d
Merge branch 'master' into fix-clang-tidy
2021-12-21 06:05:57 +00:00
Azat Khuzhin
4230f04f72
Fix UB in LimitReadBuffer in case of unexpected EOF
...
Fixes the following possible assertions:
- ./src/IO/ReadBuffer.h:58: bool DB::ReadBuffer::next(): Assertion `!hasPendingData()' failed.
- ./src/IO/LimitReadBuffer.cpp:17: virtual bool DB::LimitReadBuffer::nextImpl(): Assertion `position() >= in->position()' failed.
Fixes: 02151_http_s_structure_set_eof
2021-12-21 08:38:41 +03:00
Azat Khuzhin
08ced87880
Rework MultipartReadBuffer::skipToNextBoundary()
...
As suggested by @vitlibar
2021-12-21 08:38:41 +03:00
Azat Khuzhin
d7c7a91f66
Check that at least one boundary exist in HTMLForm::readMultipart()
2021-12-21 08:38:41 +03:00
Azat Khuzhin
4dfa9324d1
Check for EOF in MultipartReadBuffer::skipToNextBoundary()
...
Otherwise you may hit internal assertion when client goes away:
clickhouse-server: ./src/Server/HTTP/HTMLForm.cpp:245: bool DB::HTMLForm::MultipartReadBuffer::skipToNextBoundary(): Assertion `boundary_hit' failed.
Fixes: 02151_http_s_structure_set_eof
2021-12-21 08:38:41 +03:00
JackyWoo
7a19570853
keeper handler should remove operation when response sent
2021-12-21 11:43:14 +08:00
kssenii
30996b2448
Fix
2021-12-21 01:19:51 +03:00
alexey-milovidov
04fb8aeaa5
Merge pull request #32946 from antonio2368/feature/hints-for-settings
...
Hints for invalid settings in query and HTTP requests
2021-12-21 00:52:42 +03:00
kssenii
175ad8a989
Fix
2021-12-21 00:20:08 +03:00
Maksim Kita
26ea47982e
Merge pull request #32965 from save-my-heart/fix-data-part-modification-time
...
fix wrong modification_time after move part
2021-12-21 00:05:27 +03:00
Kseniia Sumarokova
2ac7897470
Merge pull request #32841 from lingtaolf/feature/add-clickhouse-client-hints
...
Add clickhouse client hints
2021-12-20 23:48:50 +03:00
Vitaly Baranov
be44743ebe
Don't throw in unexceptional cases: update().
2021-12-20 23:10:46 +03:00
Vitaly Baranov
ed94c640fa
Don't throw in unexceptional cases: remove().
2021-12-20 23:10:43 +03:00
Vitaly Baranov
551fcc55e8
Don't throw in unexceptional cases: insert().
2021-12-20 23:09:55 +03:00
mergify[bot]
e21c04ff9c
Merge branch 'master' into fix-data-part-modification-time
2021-12-20 18:58:47 +00:00
Vitaly Baranov
8c4e689da3
Don't throw in unexceptional cases: read() & readName()
2021-12-20 21:26:35 +03:00
Vitaly Baranov
a87f0b483e
Replace function IAccessStorage::canInsert() with isReadOnly().
2021-12-20 21:26:35 +03:00
Vitaly Baranov
6721060649
Rename function IAccessStorage::login() -> IAccessStorage::authenticate().
...
Remove functions IAccessStorage::hasSubscriptionImpl() and IAccessStorage::existsImpl().
2021-12-20 21:26:27 +03:00
Vitaly Baranov
c01d0f95c3
Remove the function IAccessStorage::getIDOfLoggedUser() and move its functionality to login(AlwaysAllowCredentials).
2021-12-20 21:24:38 +03:00
Azat Khuzhin
a9f80dd705
Fix Context leak in case of cancel_http_readonly_queries_on_client_close
...
To handle cancel_http_readonly_queries_on_client_close=true context
attaches progress callback with holding a copy of the current context,
and this creates recursive context reference and so shared_ptr will be
never released, [1] contains simplest example.
One example of a memory leak, external tables passed with HTTP query
(s_structure + file upload), since they are stored in the context, and
can occupate enough memory to make it visible to user.
Note, that the lifetime of the Context should be fine, since callback
can be called only when query is executed.
[1]: Example of recursive reference
```c
#include <memory>
#include <functional>
#include <cassert>
bool released = true;
class Context : public std::enable_shared_from_this<Context>
{
using Func = std::function<void()>;
Func func;
public:
Context() { released = false; }
~Context() { released = true; }
Context(const Context & context) = delete;
void addCallback(Func func_)
{
func = func_;
}
};
int main()
{
{
auto context = std::make_shared<Context>();
context->addCallback([context]() {});
}
assert(released == true);
}
```
2021-12-20 21:05:38 +03:00
Azat Khuzhin
dd8c64e380
Set QueryScope earlier for HTTP queries
2021-12-20 21:05:38 +03:00
Nikolai Kochetov
35883e0dae
Merge pull request #32979 from ClickHouse/decrease-some-s3-log-level
...
Decrease log level for some s3 messages.
2021-12-20 20:56:22 +03:00
Maksim Kita
dd0d3de050
Merge pull request #32970 from kitaisreal/loops-remove-postfix-increment
...
Loops remove postfix increment
2021-12-20 19:51:07 +03:00
Maksim Kita
daa23a2827
Merge pull request #32973 from kitaisreal/short-circuit-throw-if-support
...
Short circuit evaluation function throwIf support
2021-12-20 19:50:53 +03:00
Vitaly Baranov
e61d3eef0c
Merge pull request #32747 from vitlibar/improve-grpc-compression
...
Improve gRPC compression support
2021-12-20 19:44:58 +03:00
avogar
ba6a513db0
Fix tuple output in CSV format
2021-12-20 19:27:09 +03:00
Antonio Andelic
bc52758e4d
Explicitly default move/copy constructors
2021-12-20 17:05:08 +01:00
Antonio Andelic
25f88356e4
Add hints for SET query and HTTP request param settings
2021-12-20 16:57:09 +01:00
Nikolai Kochetov
7dea7b7f76
Decrease log level for some s3 messages.
2021-12-20 18:18:54 +03:00
Kseniia Sumarokova
a5f28e51e5
Try fix style check
2021-12-20 18:09:20 +03:00
Maksim Kita
02b6ad52ef
FunctionThrowIf fixed exception
2021-12-20 16:55:15 +03:00
Maksim Kita
ebff389701
Merge pull request #32972 from kitaisreal/containers-iteration-fix-erase
...
Containers iteration fix erase
2021-12-20 16:47:19 +03:00
avogar
e31c18e9f8
Fix hdfs url check
2021-12-20 16:09:48 +03:00
Maksim Kita
60d4295d8a
FunctionThrowIf added comment
2021-12-20 16:00:43 +03:00
Maksim Kita
51477adf1b
Updated additional cases
2021-12-20 15:55:07 +03:00
Nikolai Kochetov
2e62f086a1
Merge pull request #32751 from ClickHouse/fix-32668
...
Apply some more optimizations to NO_QUERY ast.
2021-12-20 15:47:25 +03:00
Kruglov Pavel
abbab7ff87
Merge pull request #32929 from kreuzerkrieg/get_ORC_right
...
Stop reading incomplete stripes and skip rows.
2021-12-20 15:31:48 +03:00
alesapin
5958cac72c
Merge pull request #32493 from azat/fix-02050_client_profile_events
...
Fix 02050_client_profile_events flakiness
2021-12-20 15:02:02 +03:00
Maksim Kita
20e4ce3314
Short circuit evaluation function throwIf support
2021-12-20 14:49:05 +03:00
Maksim Kita
3feab5a975
Containers iteration fix erase
2021-12-20 13:42:31 +03:00
Maksim Kita
51826c14a0
Dictionaries added Date32 type support
2021-12-20 13:39:07 +03:00
Maksim Kita
7785eac384
Loops remove postfix increment
2021-12-20 13:32:13 +03:00
Kseniia Sumarokova
967738ff8f
Merge pull request #32749 from kssenii/table-override-pg
...
Support Table Override clause for MaterializedPostgreSQL too
2021-12-20 13:11:47 +03:00
Maksim Kita
2eb9b3118e
Merge pull request #32805 from kitaisreal/cache-dictionary-dictionary-source-access-race-fix
...
CacheDictionary dictionary source access race fix
2021-12-20 12:50:16 +03:00
save-my-heart
1abe978455
fix wrong modification_time after move part
2021-12-20 16:29:06 +08:00
凌涛
0efc01be05
add test
2021-12-20 13:53:08 +08:00
kssenii
965e2bfb21
Fix
2021-12-20 08:43:07 +03:00
bharatnc
b9787f730e
use prefix increment for rows
2021-12-19 20:32:52 -08:00
bharatnc
15c555c161
simplify looping in S2 functions
...
Previously replaced range based for loops in H3 functions with simple
for loops based on review. Similarly doing the same for the S2 functions
also.
2021-12-19 20:00:28 -08:00
Azat Khuzhin
1d25ec3e82
Merge ProfileEvents in case they were not printed
...
That way with --profile-events-delay-ms=-1 you will always get totals.
Plus, this will fix periodic failures, that can be reproduced by
limitting CPU (5% is enough in my setup), i.e.:
$ systemd-run --collect --unit ch -p CPUQuota=5% --user clickhouse-server
$ while clickhouse-client --print-profile-events --profile-events-delay-ms=-1 -q 'select * from numbers (1e5) format Null' |& tee /dev/stderr | fgrep 'SelectedRows: 131010 (increment)'; do :; done
And as a bonus it will make 02050_client_profile_events deterministic.
2021-12-19 23:43:05 +03:00
Azat Khuzhin
6aebc3e94c
Do not loose ProfileEvents in case of thread destroyed before
...
v2: drop std::move and add copy ctor for ProfileEvents::Counter::Snapshot
v2: remove std::move
2021-12-19 23:43:05 +03:00
Azat Khuzhin
909ce68b5a
Do not suppress exception in ThreadStatus::~ThreadStatus()
2021-12-19 23:43:05 +03:00
kreuzerkrieg
f06c37d206
Stop reading incomplete stripes and skip rows.
2021-12-19 18:41:32 +02:00
Vitaly Baranov
02d6cea857
Lz4DeflatingWriteBuffer now supports changes in the nested buffer between calls.
2021-12-19 16:29:57 +03:00
Vitaly Baranov
708439b036
Support customized compression for input/output data in gRPC protocol.
2021-12-19 16:29:44 +03:00
alexey-milovidov
13d1377ad7
Update src/Functions/ReplaceRegexpImpl.h
...
Co-authored-by: Vladimir C <vdimir@clickhouse.com>
2021-12-19 12:59:28 +03:00
Alexey Milovidov
0d6e8e90eb
Proper fix for #30245
2021-12-19 12:44:42 +03:00
alexey-milovidov
cee850b3be
Revert "fix replaceRegexpAll bug"
2021-12-19 11:32:34 +03:00
alexey-milovidov
d1d872329c
Merge pull request #32940 from nkolotov/fix_segfault_object_used_after_move
...
Fixed segfault when smart pointer is dereferenced after move.
2021-12-19 09:36:43 +03:00
alexey-milovidov
d3a1ffd05d
Merge pull request #32529 from dmthuc/fix_groupBitmapAnd_function_distributed_table
...
fix groupBitmapAnd function on distributed table
2021-12-19 08:28:26 +03:00
alexey-milovidov
74c2a38ea5
Merge pull request #32592 from ClickHouse/strange-code-tcphandler
...
Fix strange code in TCPHandler
2021-12-19 08:11:43 +03:00
mergify[bot]
4580af9f79
Merge branch 'master' into fix_segfault_object_used_after_move
2021-12-19 04:33:03 +00:00
N. Kolotov
b059154a81
Fixed segfault when smart pointer is dereferenced after move.
2021-12-18 23:13:42 +03:00
Denny Crane
293191247f
Update RemoteQueryExecutor.h
2021-12-18 15:50:16 -04:00
Denny Crane
aa52eff0ec
fix typo
2021-12-18 15:48:23 -04:00
Vladimir C
778cd76987
Merge pull request #32914 from vdimir/issue_32487
2021-12-18 10:18:51 +03:00
alexey-milovidov
5cd56b127f
Merge pull request #32912 from cmsxbc/fix-wrong-cases-in-gtest-parser
...
fix wrong testcase in gtest_Parser
2021-12-18 07:51:16 +03:00
alexey-milovidov
8571501cf7
Update AggregateFunctionTopK.cpp
2021-12-18 07:49:35 +03:00
kssenii
e6ebb55c4e
Move to Interpreters
2021-12-17 22:19:10 +03:00
kssenii
dd902b6875
Merge remote-tracking branch 'upstream/master' into table-override-pg
2021-12-17 22:03:58 +03:00
alexey-milovidov
6b97af4c63
Merge pull request #26869 from taylor12805/grouping-sets-dev
...
Grouping sets dev
2021-12-17 20:50:15 +03:00
Nikolai Kochetov
ffdcf52a9e
Merge pull request #32858 from ClickHouse/fix-has-column-in-table-subquery-2
...
Always apply const-condition-if optimization.
2021-12-17 20:39:30 +03:00