Commit Graph

975 Commits

Author SHA1 Message Date
Alexey Milovidov
66f495b690 Fix build 2021-03-04 06:49:46 +03:00
Alexey Milovidov
4e8239e098 Merge branch 'master' into DateTime64_extended_range 2021-03-03 23:43:20 +03:00
alexey-milovidov
a1424bc675
Merge pull request #21365 from azat/clickhouse-stop-kill-wait
clickhouse stop: wait for the server to be killed (process exited)
2021-03-03 02:11:17 +03:00
Azat Khuzhin
41a8c2f8fa clickhouse stop: wait for the server to be killed (process exited)
Since killing doesn't happen instantly, and the start will fail [1]:

    The process with pid = 157 is running.
    Will terminate forcefully.
    Sent kill signal.
    /var/run/clickhouse-server/clickhouse-server.pid file exists and contains pid = 157.
    The process with pid = 157 is already running.
    + for _ in {1..120}
    + clickhouse-client --query 'SELECT 1'
    Code: 210. DB::NetException: Connection refused (localhost:9000)

  [1]: https://clickhouse-test-reports.s3.yandex.net/21318/4327e9e1d1e4c9c3576b00f41a8444237549dffd/functional_stateful_tests_(debug).html#fail1
2021-03-02 09:45:03 +03:00
Azat Khuzhin
0e68fc67aa Add other distributed_ddl settings into config.xml as an example 2021-02-28 05:45:12 +03:00
Azat Khuzhin
dfd1c73b31 Load dictionaries before starting accepting connections and DDLWorker 2021-02-28 05:45:12 +03:00
Alexey Milovidov
ac4d3b504e Allow to start up with modified binary under gdb 2021-02-26 20:15:11 +03:00
Vasily Nemkov
2d03d330bc Extended range of DateTime64 to years 1925 - 2238
The Year 1925 is a starting point because most of the timezones
switched to saner (mostly 15-minutes based) offsets somewhere
during 1924 or before. And that significantly simplifies implementation.

2238 is to simplify arithmetics for sanitizing LUT index access;
there are less than 0x1ffff days from 1925.

* Extended DateLUTImpl internal LUT to 0x1ffff items, some of which
  represent negative (pre-1970) time values.
  As a collateral benefit, Date now correctly supports dates up to 2149
  (instead of 2106).
* Added a new strong typedef ExtendedDayNum, which represents dates
  pre-1970 and post 2149.
* Functions that used to return DayNum now return ExtendedDayNum.
* Refactored DateLUTImpl to untie DayNum from the dual role of being
  a value and an index (due to negative time). Index is now a different
  type LUTIndex with explicit conversion functions from DatNum, time_t,
  and ExtendedDayNum.
* Updated DateLUTImpl to properly support values close to epoch start
  (1970-01-01 00:00), including negative ones.
* Reduced resolution of DateLUTImpl::Values::time_at_offset_change
  to multiple of 15-minutes to allow storing 64-bits of time_t in
  DateLUTImpl::Value while keeping same size.
* Minor performance updates to DateLUTImpl when building month LUT
  by skipping non-start-of-month days.
* Fixed extractTimeZoneFromFunctionArguments to work correctly
  with DateTime64.
* New unit-tests and stateless integration tests for both DateTime
  and DateTime64.
2021-02-24 17:08:35 +02:00
tavplubix
a697b578bc
Merge pull request #16193 from ClickHouse/database_replicated
DatabaseReplicated: continuation of #10485
2021-02-20 19:39:34 +03:00
alexey-milovidov
e336abad1c
Merge pull request #20981 from azat/http-client-reset-uncaught-exception
Fix uncaught exception when HTTP client goes away
2021-02-20 16:30:04 +03:00
Azat Khuzhin
5d36ceaaee Fix WriteBufferFromHTTPServerResponse usage in odbc-bridge 2021-02-20 10:15:38 +03:00
alexey-milovidov
b4196c8e68
Merge pull request #20168 from ClickHouse/in-memory-compression
Compression for Memory tables
2021-02-20 09:49:37 +03:00
alexey-milovidov
4390cb3d73
Update config.xml 2021-02-20 09:49:02 +03:00
Ivan
414f470c79
Make Poco HTTP Server zero-copy again (#19516)
* Refactoring: part 1

* Refactoring: part 2

* Handle request using ReadBuffer interface

* Struggles with ReadBuffer's

* Fix URI parsing

* Implement parsing of multipart/form-data

* Check HTTP_LENGTH_REQUIRED before eof() or will hang

* Fix HTTPChunkedReadBuffer

* Fix build and style

* Fix test

* Resist double-eof

* Fix arcadian build
2021-02-19 15:51:26 +03:00
Alexander Tokmakov
bf6f64a3fb Merge branch 'master' into database_replicated 2021-02-16 01:28:19 +03:00
Alexander Tokmakov
9c7cf9e92e remove some debug code 2021-02-15 13:26:34 +03:00
Alexey Milovidov
ddb2cbcf6d Merge branch 'master' into in-memory-compression 2021-02-14 04:32:41 +03:00
alesapin
f80137626a
Merge pull request #19580 from ClickHouse/in_memory_raft
In memory coordination inside ClickHouse
2021-02-13 10:19:23 +03:00
alexey-milovidov
2fe2190a20
Merge pull request #19721 from azat/buffer-profile
Add separate config directive for Buffer profile
2021-02-13 02:43:41 +03:00
alesapin
5f32f65211 Merge branch 'master' into in_memory_raft 2021-02-11 23:09:29 +03:00
Alexey Milovidov
4d650a2a56 Adjust config 2021-02-11 16:41:21 +03:00
Alexey Milovidov
58f1d4d910 Add comment to config 2021-02-11 16:41:21 +03:00
Alexander Kuzmenkov
2571dac984
Merge pull request #20111 from ClickHouse/aku/window-prototype
RANGE OFFSET window frame
2021-02-11 10:39:21 +03:00
alexey-milovidov
8553a65ef8
Merge pull request #20281 from ClickHouse/aku/fuzzer-changed-settings
print changed settings in fuzzer when the server dies
2021-02-11 03:26:01 +03:00
Azat Khuzhin
935870b2c2 Add separate config directive for Buffer profile
If you push data via Buffer engine then all your queries will be done
from one user, however this is not always desired behavior, since this
will not allow to limit queries with max_concurrent_queries_for_user and
similar.
2021-02-10 21:40:26 +03:00
alexey-milovidov
76ccec2885
Fix XML 2021-02-10 16:39:59 +03:00
Alexander Kuzmenkov
87e5218c91
Update Client.cpp 2021-02-10 16:29:33 +03:00
Alexander Kuzmenkov
41a3cd978e print changed settings in fuzzer when the server dies 2021-02-10 14:18:11 +03:00
filimonov
beb5912b4f
Add example of client configuration adjusemtents 2021-02-10 10:02:35 +01:00
alesapin
9667bdcbd2 Merge branch 'master' into in_memory_raft 2021-02-09 16:06:31 +03:00
alesapin
d5ee7d33e9 Merge branch 'master' into in_memory_raft 2021-02-08 10:30:31 +03:00
madianjun
198a8d3b27 Drop helping tables when the whole table is done in clickhouse-copier 2021-02-08 10:54:03 +08:00
alexey-milovidov
ed5a81ab59
Merge pull request #20078 from abyss7/better-read-buffers-4
LimitReadBuffer: check that position always advances
2021-02-07 07:33:08 +03:00
alesapin
011109c82a
Merge pull request #17348 from xjewer/alex/CLICKHOUSE-606_deduplication_UUID
CLICKHOUSE-606: query deduplication based on parts' UUID
2021-02-05 22:47:34 +03:00
Alexander Kuzmenkov
6824f13a35 tmp 2021-02-05 12:13:19 +03:00
Ivan Lezhankin
ee0ff755e2 Check that position always advances 2021-02-04 17:46:46 +03:00
Alexander Kuzmenkov
f31d2206a7 more fuzzing and less bugs 2021-02-03 15:50:25 +03:00
Alexander Kuzmenkov
bb45c5a8ff Merge remote-tracking branch 'origin/master' into HEAD 2021-02-03 12:13:23 +03:00
Alexander Kuzmenkov
a164abf23e add frame fuzzing and one query that fails under msan 2021-02-03 09:42:54 +03:00
Aleksei Semiglazov
921518db0a CLICKHOUSE-606: query deduplication based on parts' UUID
* add the query data deduplication excluding duplicated parts in MergeTree family engines.

query deduplication is based on parts' UUID which should be enabled first with merge_tree setting
assign_part_uuids=1

allow_experimental_query_deduplication setting is to enable part deduplication, default ot false.

data part UUID is a mechanism of giving a data part a unique identifier.
Having UUID and deduplication mechanism provides a potential of moving parts
between shards preserving data consistency on a read path:
duplicated UUIDs will cause root executor to retry query against on of the replica explicitly
asking to exclude encountered duplicated fingerprints during a distributed query execution.

NOTE: this implementation don't provide any knobs to lock part and hence its UUID. Any mutations/merge will
update part's UUID.

* add _part_uuid virtual column, allowing to use UUIDs in predicates.

Signed-off-by: Aleksei Semiglazov <asemiglazov@cloudflare.com>

address comments
2021-02-02 16:53:39 +00:00
alesapin
9979181c02 Merge branch 'master' into in_memory_raft 2021-02-02 17:05:20 +03:00
alexey-milovidov
f5dc38a33c
Merge pull request #19584 from azat/client-complete-error-codes
client: more suggestions
2021-02-02 11:05:17 +03:00
alesapin
d265e3b419 Less timeouts 2021-02-02 11:02:25 +03:00
alexey-milovidov
8c0ec5105b
Add a patch from @FishermanZzhang, #19952 2021-02-02 06:53:11 +03:00
Azat Khuzhin
37797fdf5b Merge remote-tracking branch 'upstream/master' into client-complete-error-codes 2021-02-02 00:14:53 +03:00
alesapin
f6a8c90be2 Fix config path 2021-02-01 18:12:00 +03:00
alesapin
a8d30bedea Missed config file 2021-02-01 17:16:37 +03:00
alesapin
365bf65f5a Fix install script 2021-02-01 17:14:59 +03:00
alesapin
57c9b6c864 Fix build without nuraft 2021-02-01 16:18:17 +03:00
alesapin
0aca40d8cb Merge branch 'master' into in_memory_raft 2021-02-01 14:30:11 +03:00