Mike Kot
38232c286d
fixing paths
2021-10-02 21:45:05 +02:00
Mike Kot
65e6e211b4
Merge remote-tracking branch 'upstream/master' into improvement/fn-traits
2021-10-02 21:37:50 +02:00
Anton Popov
1f10246a10
Merge remote-tracking branch 'upstream/master' into HEAD
2021-10-02 22:33:27 +03:00
Alexey Milovidov
2ad5dbdfe8
Rename "common" to "base"
2021-10-02 11:30:38 +03:00
Alexey Milovidov
fe6b7c77c7
Rename "common" to "base"
2021-10-02 10:13:14 +03:00
Azat Khuzhin
cab0551c5b
Add ability to compile using newer version fo glibc w/o using new symbols
...
In glibc 2.32 new version of some symbols had been added [1]:
$ nm -D clickhouse | fgrep -e @GLIBC_2.32
U pthread_getattr_np@GLIBC_2.32
U pthread_sigmask@GLIBC_2.32
[1]: https://www.spinics.net/lists/fedora-devel/msg273044.html
Right now ubuntu 20.04 is used as official image for building
ClickHouse, however once it will be switched someone may not be happy
with that fact that he/she cannot use official binaries anymore because
they have glibc < 2.32.
To avoid this dependency, let's force previous version of those
symbols from glibc.
Note, that I've tested this by compiling with glibc 2.32 and verifying
that output ELF does not have @GLIBC_2.32 symbols and also running that
binary inside ubuntu:20.04 image (that has glibc 2.31).
v1: -Wl,--wrap
v2: -Wl,--defsym
v3: -include
v4: fix versioning for aarch64
2021-10-01 21:01:59 +03:00
Mike Kot
e8625e85a4
Fixing integration tests
2021-10-01 19:13:14 +02:00
Mike Kot
38b02b121a
Merge remote-tracking branch 'upstream/master' into improvement/fn-traits
2021-10-01 16:55:28 +02:00
Mike Kot
5e560ff9d7
fix
2021-10-01 16:55:01 +02:00
Anton Popov
515cc74530
generalize code in IColumn::updatePermutation
2021-10-01 00:11:54 +03:00
Azat Khuzhin
a4f2663b82
Log queries to external databases (since they may be rewriten)
...
By rewritten means that some expression from WHERE can be removed, yes
there is external_table_strict_query, but sometimes it is too strict.
2021-09-29 21:56:28 +03:00
Mike Kot
7670ea50c1
Replacing std::function to Fn in some places
...
to avoid dynamic allocating while keeping desired function signature
clear.
Simplifying SimpleCache (CachedFn) using C++20
2021-09-29 13:09:39 +02:00
Alexey Milovidov
cd7f9d981c
Remove ya.make
2021-09-25 04:22:54 +03:00
Alexander Tokmakov
72b1b2e360
Merge branch 'master' into mvcc_prototype
2021-09-23 22:53:27 +03:00
Alexey Milovidov
894f4908fa
Add comments
2021-09-19 22:26:16 +03:00
Alexey Milovidov
86f38283ff
Merge branch 'master' into better-memequal
2021-09-19 21:54:15 +03:00
alexey-milovidov
20d8523a2e
Merge pull request #28888 from azat/mysql-in-fix
...
Fix queries to external databases (i.e. MySQL) with multiple columns in IN ( i.e. `(k,v) IN ((1, 2))` )
2021-09-18 15:53:40 +03:00
alexey-milovidov
c4b3add859
Update Query.cpp
2021-09-18 15:46:48 +03:00
Maksim Kita
7c748b6140
Merge pull request #27963 from zhanglistar/overflow_bugfix
...
Overflow bugfix
2021-09-15 23:31:43 +03:00
Sergei Semin
12e24a23d3
Merge branch 'master' into fix-build-clang-13-2
2021-09-12 19:30:55 +03:00
alexey-milovidov
ea13a8b562
Merge pull request #28659 from myrrc/improvement/tostring_to_magic_enum
...
Improving CH type system with concepts
2021-09-12 15:26:29 +03:00
Sergei Semin
f74350c148
fix special build
2021-09-12 02:49:31 +03:00
Mike Kot
3401b32e37
Adapted usage of is_decimal concept
2021-09-11 19:35:12 +02:00
Azat Khuzhin
c77c4e22ae
Add MySQL query into after transformation in case of BadQuery
...
Since it may differs from the user input
2021-09-11 14:06:19 +03:00
mergify[bot]
5db3ba7414
Merge branch 'master' into better-memequal
2021-09-11 02:54:07 +00:00
Mike Kot
bce011cb33
Replacing IsDecimalNumber
2021-09-11 00:40:18 +02:00
Mike Kot
c4385a2c40
Simplifying exception messages
2021-09-11 00:40:18 +02:00
Sergei Semin
baa7253677
fix -Wreserved-identifier in base/daemon/BaseDaemon.cpp
2021-09-10 11:41:49 +03:00
Sergei Semin
61d46c09ee
fix problem with phdr_cache.cpp (second try)
2021-09-09 23:51:47 +03:00
Sergei Semin
ecff16de48
ignore diagnostic -Wreserved-identifier in file base/common/unit.h
2021-09-09 23:51:47 +03:00
Sergei Semin
39929e52bd
add ignore of -Wreserved-identifier into LineReader.cpp, ThreadFuzzer.cpp, ReadBufferFromFileDescriptor.cpp
2021-09-09 23:51:47 +03:00
Sergei Semin
a46d23fa79
ignore reserved-macro-identifier when building lib mysqlxx
2021-09-09 23:51:47 +03:00
Sergei Semin
a7b2867d3d
fix reserved-identifier in readpassphrase.c
2021-09-09 23:51:47 +03:00
Sergei Semin
338020e8ed
rename __lsan_ignore_object --> lsan_ignore_object in phdr_cache.cpp
2021-09-09 23:51:47 +03:00
Alexey Milovidov
81975a00fe
Better memequal implementation
2021-09-09 05:42:13 +03:00
Alexey Milovidov
0e8b4e608b
Better memequal implementation
2021-09-09 05:38:48 +03:00
Dmitrii Kovalkov
b073d5a4b4
Default argument for Pool.get()
2021-09-08 13:11:38 +03:00
Maksim Kita
7a4a0b0ede
Merge pull request #28474 from azat/mysql-connection_no_block
...
Introduce connection_wait_timeout for MySQL engine.
2021-09-07 12:28:02 +03:00
Mike Kot
8e9aacadd1
Initial: replacing hardcoded toString for enums with magic_enum
2021-09-06 16:24:03 +02:00
alesapin
497c225203
Test log level for CI
2021-09-03 13:07:40 +03:00
Azat Khuzhin
ed70ed6f71
Introduce connection_no_wait setting for MySQL engine.
...
This will allow to avoid superfluous sleep during query execution, since
this not only not desired behavoiur, but also may hang the server, since
if you will execute enough queries that will use MySQL database but will
not allow enough connections (or your MySQL server is too slow) then you
may run out of threads in the global thread pool.
Also note that right now it is possible to get deadlock when the mysql
pool is full, consider the following scenario:
- you have m1 and m2 mysql tables
- you have q1 and q2 queries, bot queries join m1 and m2
- q1 allocated connection for m1 but cannot allocate connection for m2
- q2 allocated connection for m2 but cannot allocate connection for m1
- but to resolve the lock one should give up on the locking while it is not possible right now...
And then you got no free threads and this:
# grep -h ^202 /proc/$(pgrep clickhouse-serv)/task/*/syscall | cut -d' ' -f2 | sort | uniq -c | sort -nr | head
1554 0x7ffb60b92fe8 # mutex in mysqlxx::PoolWithFailover::get
1375 0x7ffb9f1c4748 # mutex in ::PoolEntryHelper::~PoolEntryHelper from DB::MultiplexedConnections::invalidateReplica
1160 0x7ffb612918b8 # mutex in mysqlxx::PoolWithFailover::get
42 0x7ffb9f057984 # mutex in ThreadPoolImpl<std::__1::thread>::worker
*NOTE: 202 is a `futex` with WAIT*
(Went with `syscall` because debugging 10k+ threads is not easy, and
eventually it may TRAP)
2021-09-02 22:23:37 +03:00
Maksim Kita
e5ee3752ef
BorrowedObjectPool fix style
2021-09-02 16:18:10 +03:00
tavplubix
c36fe210b8
Revert "Add test for #13398 "
2021-08-27 21:07:10 +03:00
Kruglov Pavel
5bc332c40c
Merge pull request #28054 from kssenii/mysql
...
Add test for #13398
2021-08-26 16:39:43 +03:00
alexey-milovidov
c6f40c5c2d
Revert "Revert "less sys calls #2 : make vdso work again""
2021-08-25 14:19:20 +03:00
kssenii
0d5000f917
Merge branch 'master' of https://github.com/ClickHouse/ClickHouse into mysql
2021-08-24 07:30:42 +00:00
kssenii
962f415740
Add test and settings
2021-08-23 22:18:04 +00:00
Vitaly Baranov
c1177ee562
Support implicit cast std::pair<UInt64, UInt64> to UInt128.
2021-08-23 23:41:45 +03:00
Vitaly Baranov
9a5eeb5d41
Add utility function insertAtEnd().
2021-08-23 23:41:45 +03:00
Vladimir C
bce6d092ea
Merge pull request #27858 from ianton-ru/MDB-14264
...
Use Multipart copy upload for large S3 objects
2021-08-23 11:32:19 +03:00
listar
b4a33ce001
1. fix oveflow bug
2021-08-21 19:08:34 +00:00
vdimir
e77ff2740a
Add common/unit.h
2021-08-20 13:57:05 +03:00
tavplubix
9ef45d92c2
Merge pull request #27755 from ClickHouse/ncb/server_uuid
...
Merging #20089
2021-08-19 14:59:18 +03:00
alexey-milovidov
8f280c9ccb
Merge pull request #27829 from ClickHouse/revert-27492-less_clock_gettime2
...
Revert "less sys calls #2 : make vdso work again"
2021-08-19 12:50:50 +03:00
alexey-milovidov
3db3b40b5e
Revert "less sys calls #2 : make vdso work again"
2021-08-19 01:38:12 +03:00
Alexander Tokmakov
31d75c9c38
fix split build
2021-08-18 15:15:31 +03:00
Sergei Semin
da3f5612ae
rename _Bits -> _bits
2021-08-17 23:08:17 +03:00
Alexander Tokmakov
df1a4e90a8
Merge branch 'master' into ncb/server_uuid
2021-08-17 19:42:47 +03:00
Alexander Tokmakov
4d71f65082
fix build
2021-08-17 16:24:14 +03:00
Alexander Tokmakov
9e9fa043ca
minor improvements, add test
2021-08-16 21:30:53 +03:00
Alexey Milovidov
9a4a8d3943
Fix build with clang-13
2021-08-16 03:16:45 +03:00
Alexey Milovidov
f063e44131
Whitespaces
2021-08-15 09:00:28 +03:00
alexey-milovidov
fe356a716e
Merge pull request #27492 from filimonov/less_clock_gettime2
...
less sys calls #2 : make vdso work again
2021-08-13 03:13:11 +03:00
Vitaly Baranov
213e6366c2
Update getauxval.c
2021-08-12 13:44:09 +03:00
Vitaly Baranov
3d9a4adfbf
Better handling case when __environ is null
2021-08-12 13:43:06 +03:00
Maksim Kita
34682c98c7
Merge pull request #27605 from Enmk/fix_27193_toDateTime64_conversion
...
Fixed parsing DateTime64 value from string.
2021-08-12 13:32:59 +03:00
Vitaly Baranov
9243e89150
Update getauxval.c
2021-08-12 12:10:37 +03:00
Vitaly Baranov
242d8e1861
__auxv_init lazy initialization
2021-08-12 11:06:12 +02:00
Mikhail Filimonov
2c01e2789a
make vdso work again
2021-08-12 11:06:06 +02:00
Vasily Nemkov
bdc4d9fe75
Fixed parsing DateTime64 value from string.
...
The time offset undeflowed on positive values.
2021-08-12 10:37:46 +03:00
Raúl Marín
8bae14acb1
Separate minute intervals
...
Instead of mixing multiple rounding, use toStartOfMinuteInterval for all
minute related calculations
2021-08-10 17:01:56 +02:00
Raúl Marín
ede5369265
Revert toMinute changes and add additional roundDown fastpath
2021-08-10 12:55:49 +02:00
Raúl Marín
0771329bf3
Improvements based on review
2021-08-09 16:16:17 +02:00
Raúl Marín
367b314df6
Linter
2021-08-09 15:45:51 +02:00
Raúl Marín
5921f0cc82
Make gcc happy
2021-08-09 15:45:51 +02:00
Raúl Marín
abeaf60e4a
Improve compatibility with non-whole-minute timezone offsets
2021-08-09 15:45:51 +02:00
Alexey Milovidov
7fa700de00
Merge branch 'master' into roaring-memory-tracker
2021-08-05 22:17:10 +03:00
alexey-milovidov
44441535ff
Update BaseDaemon.cpp
2021-07-30 09:21:03 +03:00
Nikolai Kochetov
3d029e66fe
Update BaseDaemon.cpp
2021-07-29 17:00:33 +03:00
Nikolai Kochetov
3b8cb7e4bf
Print trace from std::terminate exception line-by-line to make it grep easier.
2021-07-29 15:49:31 +03:00
Alexander Tokmakov
c74bfbf991
Merge branch 'master' into mvcc_prototype
2021-07-28 22:21:48 +03:00
Vitaly Baranov
19d5a6ab2f
Merge pull request #26714 from vitlibar/new-function-current-profiles
...
New functions currentProfiles(), enabledProfiles(), defaultProfiles().
2021-07-23 09:10:29 +03:00
Vitaly Baranov
7afcc65060
Add new functions currentProfiles(), enabledProfiles(), defaultProfiles().
2021-07-22 22:20:53 +03:00
Alexey Milovidov
2df3e14559
Attempt to add memory tracking to RoaringBitmaps
2021-07-22 02:56:17 +03:00
Azat Khuzhin
cfc79d9146
Fix history file conversion if file is empty
2021-07-20 21:00:53 +03:00
kssenii
3ba2d114d5
Revert "Merge pull request #26352 from ClickHouse/revert-25774-datatype-date32"
...
This reverts commit 94a210650f
, reversing
changes made to 0893b9ff8e
.
2021-07-15 11:41:52 +00:00
alexey-milovidov
9ba4064c86
Revert "Datatype Date32, support range 1925 to 2283"
2021-07-15 10:53:35 +03:00
neng.liu
dfe05ca583
fix test error
2021-07-11 06:14:03 -07:00
neng.liu
4669839fbb
add comment and update ya.make
2021-07-11 04:55:42 -07:00
NengLiu
78f0bb9e24
add type cast
2021-07-09 15:28:44 +08:00
NengLiu
1d7d973dea
change addWeeks delta's datatype from Int64 to Int32
2021-07-09 11:42:32 +08:00
NengLiu
e172ca240b
change addQuarter delta's datatype from Int64 to Int32
2021-07-09 11:35:12 +08:00
neng.liu
e47aadfdef
Merge branch 'datatype-date32' of https://github.com/liuneng1994/ClickHouse into datatype-date32
2021-07-08 00:09:48 -07:00
neng.liu
100d30a5ba
fix pr comment
2021-07-08 00:06:36 -07:00
NengLiu
8b88988618
Merge branch 'master' into datatype-date32
...
# Conflicts:
# src/DataStreams/PostgreSQLBlockInputStream.cpp
2021-07-05 10:18:38 +08:00
NengLiu
dc0c65ef4f
Merge remote-tracking branch 'origin/master' into datatype-date32
2021-07-05 10:15:08 +08:00
alexey-milovidov
fef7c557f6
Merge pull request #24789 from kitaisreal/compile-aggregation-functions
...
Compile aggregate functions
2021-07-05 02:57:49 +03:00
Maksim Kita
55220d49f9
Fixed code review issues
2021-07-03 16:29:32 +03:00
feng lv
1d332da0ed
fix special build on clang 11
2021-07-02 05:51:53 +00:00
alexey-milovidov
24759a9b67
Update ReplxxLineReader.cpp
2021-07-02 04:26:49 +03:00
alexey-milovidov
a41a1b7c74
Update ReplxxLineReader.cpp
2021-07-02 04:25:07 +03:00
Maksim Kita
9b71b1040a
Aggregate functions update compile interface
2021-07-01 22:56:35 +03:00
Maksim Kita
3fe559b31f
Compile aggregate functions
2021-07-01 22:56:35 +03:00
Azat Khuzhin
626f47e044
Convert history file from readline format to replxx format
...
replxx requires each history line to prepended with time line:
### YYYY-MM-DD HH:MM:SS.SSS
select 1
And w/o those service lines it will load all lines from history file as
one history line for suggestion. And if there are lots of lines in file it
will take lots of time (getline() + tons of reallocations).
2021-06-30 22:06:16 +03:00
NengLiu
00377e7c9b
fix style error
2021-06-30 17:29:13 +08:00
Alexey Milovidov
d611297a7f
Add comment
2021-06-29 02:19:09 +03:00
Alexey Milovidov
f4f85a387d
Fix DateLUT on Darwin
2021-06-29 02:16:19 +03:00
neng.liu
ec7604b013
add parquet test and fix add interval error when type is date32
2021-06-28 16:36:54 +08:00
Ivan
14e43cfafa
Add CI check for darwin-aarch64 ( #25560 )
...
* Add support for darwin-aarch64
* Fix PVS warnings
* Add build configuration
* Fix packager args
2021-06-25 18:21:56 +03:00
Neng Liu
aadc2af5cb
add some functional test
2021-06-22 19:10:56 +08:00
Neng Liu
7ed1728a37
Merge branch 'master' into datatype-date32
...
# Conflicts:
# src/DataTypes/IDataType.h
# src/Functions/CustomWeekTransforms.h
2021-06-22 10:00:18 +08:00
Evgeniy Gatov
2487063be3
METR-41529
2021-06-21 22:31:42 +03:00
Azat Khuzhin
4dcbf3a5c5
Replace __pthread_get_minstack() with a const
2021-06-20 14:03:04 +03:00
Azat Khuzhin
0286673f8f
Fix __pthread_get_minstack()
...
This is the function that should take into account TLS block, and 1MB is
too high, since it will be used for sigaltstack() on SIGSEGV
v0: copy-paste glibc __pthread_get_minstack()
v2: return static 16K instead of 1MB
2021-06-19 21:27:02 +03:00
alexey-milovidov
48980b9c31
Merge pull request #25279 from ClickHouse/fix-wide-int-ub
...
Fix incorrect behaviour and UBSan report in big integers.
2021-06-17 01:35:48 +03:00
Maksim Kita
67e9b85951
Merge ext into common
2021-06-16 23:28:41 +03:00
Kseniia Sumarokova
b4840bc4a9
Merge pull request #25280 from kssenii/bridges-constraints
...
Privilege drop and resource constraints for bridge processes
2021-06-16 22:13:16 +03:00
Maksim Kita
67884ec50c
SimpleCache key constructor improvement
2021-06-16 01:40:16 +03:00
Alexey Milovidov
c41b58b148
Fix UBSan report
2021-06-15 06:52:49 +03:00
kssenii
b152d7589f
Bridge contsraints
2021-06-15 01:01:10 +00:00
Alexey Milovidov
3ee26c822d
Remove unused function
2021-06-15 03:30:01 +03:00
Alexey Milovidov
6eb06d84d4
Fix decomposed float
2021-06-15 03:29:44 +03:00
Alexey Milovidov
c5181cf897
Fix wrong code in wide_int
2021-06-15 03:29:20 +03:00
Alexey Milovidov
6738774722
Minor change
2021-06-13 21:54:55 +03:00
alexey-milovidov
a2c6b98b94
Merge pull request #25146 from oxidecomputer/master
...
Adds a better way to include binary resources
2021-06-13 16:13:34 +03:00
Benjamin Naecker
f5cf9adc66
Removes unused CMake variable and fixes clang-tidy lint
2021-06-11 14:35:40 -07:00
Benjamin Naecker
e4e0bd557a
Style fix
2021-06-09 15:53:56 -07:00
Benjamin Naecker
c3506bf16d
Adds a better way to include binary resources
...
- Uses a small assembly file to include binary resources, rather than
objcopy
- Updates `base/common/getResource.cpp` for this new method of inclusion
- Removes linux-only guards in CMake files, as this solution is
cross-platform.
The resulting binary resources are available in the ClickHouse server
binary on Linux, macOS, and illumos platforms. FreeBSD has not been
tested, but will likely work as well.
2021-06-09 14:03:30 -07:00
Alexander Tokmakov
6f5cf773ef
Merge branch 'master' into mvcc_prototype
2021-06-09 12:50:54 +03:00
Neng Liu
88a0d0be62
add datetype32 part2
2021-06-08 20:31:41 +08:00
neng.liu
120da1fd73
date32 initial code
2021-06-07 06:41:58 -07:00
Azat Khuzhin
c65ae8ac31
Do not check writeRetry errors in OwnSplitChannel
...
Should fix PVS warning:
"There are identical sub-expressions '!writeRetry(2, "\n")' to the left and to the right of the '||' operator."
2021-06-07 09:40:29 +03:00
Azat Khuzhin
3d9218dbfa
Use writeRetry in case of exception during writing to the log
2021-06-07 09:38:15 +03:00
Azat Khuzhin
b9c869871b
Block memory tracking during catching exceptions in OwnSplitChannel
2021-06-07 09:38:15 +03:00
Azat Khuzhin
89a4d886bf
Suppress exceptions from logger code
...
Some code does not expect from the logger code to throw, and this can
lead to the problems like:
- marking distributed batch as broken (in
StorageDistributedDirectoryMonitor)
- some MergeTree code may also be affected.
So instead of throwing the exception, it will be logged to the stderr
(if it is possible).
2021-06-07 09:38:15 +03:00
Alexander Tokmakov
9915bd0a8b
Merge branch 'master' into mvcc_prototype
2021-06-03 00:52:57 +03:00
Alexander Tokmakov
5692db736c
Merge branch 'master' into mvcc_prototype
2021-05-31 21:11:22 +03:00
kssenii
2a631aaf08
Final fixes
2021-05-29 00:34:44 +03:00
kssenii
f66c67a979
Fixes
2021-05-27 15:42:46 +03:00
kssenii
31107816bb
fs::absolute to fs::canonical
2021-05-24 20:37:54 +03:00
kssenii
866b29fb5a
Return list fds with Poco, more canonical
2021-05-23 10:56:13 +03:00
kssenii
1c43b333ea
Merge branch 'master' of github.com:ClickHouse/ClickHouse into poco-file-to-std-fs
2021-05-22 21:26:48 +03:00
kssenii
8bac10d24f
Update base/*
2021-05-22 21:24:13 +03:00
Vitaly Baranov
b89da7b420
Merge pull request #21858 from BoloniniD/yaml-cfg
...
YAML Configuration for ClickHouse
2021-05-22 10:29:51 +03:00
BoloniniD
33755f1f3d
Implemented YAMLParser class
2021-05-21 21:56:22 +03:00
Azat Khuzhin
4f41ebcae3
Add settings (for connections) for MySQL storage engine
...
Default settings are not very efficient, since they do not even reuse
connections.
And when each query requires connection you can have only ~80 QPS, while
by simply enabling connection reuse (connection_auto_close=false) you
can have ~500 QPS (and by increasing connection_pool_size you can have
better QPS throughput).
So this patch allows to pass through some connection related settings
for the StorageMySQL engine, like:
- connection_pool_size=16
- connection_max_tries=3
- connection_auto_close=true
v2: remove connection_pool_default_size
v3: remove num_tries_on_connection_loss
2021-05-20 22:44:52 +03:00
Alexander Tokmakov
529d1aeb19
fix merges of uncommitted parts
2021-05-18 20:07:29 +03:00
alesapin
83627de2b8
Merge branch 'master' into standalone_keeper
2021-05-15 17:15:06 +03:00
Kruglov Pavel
7b26483080
Rename param
2021-05-13 16:37:44 +03:00
Kruglov Pavel
fb17078af3
Merge branch 'master' into filimonov-logger-levels
2021-05-13 16:10:01 +03:00
alesapin
41eadf9127
Something working
2021-05-12 16:04:34 +03:00
Alexey Milovidov
9753ddc8a0
Merge branch 'master' of github.com:yandex/ClickHouse into normalize-bigint
2021-05-09 18:54:29 +03:00
Alexey Milovidov
3b2f897f3a
Fix UBSan
2021-05-09 02:25:36 +03:00
Alexey Milovidov
037d06bb2a
Fix warnings by PVS-Studio
2021-05-08 23:50:12 +03:00
Alexey Milovidov
0af587a346
Fix warnings by PVS-Studio in some third-party code
2021-05-08 22:31:11 +03:00
Alexey Milovidov
604daa9581
Fix a bunch of warnings from PVS-Studio
2021-05-08 19:09:17 +03:00
Alexey Milovidov
9e1a5f41fc
A bunch of changes for PVS-Studio
2021-05-08 17:43:03 +03:00
Alexey Milovidov
e9c7aa5ab5
Remove some code
2021-05-08 17:12:26 +03:00
divanorama
b6ea00cf29
Update glibc_compatibility check: ARCH_ARM -> ARCH_AARCH64
2021-05-08 14:24:04 +02:00
Alexey Milovidov
597dcc3e59
Remove packed
2021-05-08 03:06:35 +03:00
Alexey Milovidov
74e2d61207
Fix typo
2021-05-08 03:05:12 +03:00
Alexey Milovidov
d0f1931ecc
Fix ugly typo
2021-05-08 01:22:07 +03:00
Alexey Milovidov
690b2d74fd
Fix gcc build
2021-05-08 01:18:42 +03:00
Alexey Milovidov
8334d8aac1
Speedup division
2021-05-08 01:07:57 +03:00
Alexey Milovidov
ca18f8bef1
Fix division of big integers; add a test
2021-05-08 00:47:23 +03:00
Alexey Milovidov
7443e660ea
Remove unused headers
2021-05-07 20:13:00 +03:00
Alexey Milovidov
9db3cd57bb
Supposedly fix error with shifts; add a test
2021-05-07 20:12:14 +03:00
Alexey Milovidov
1a746f124f
Style
2021-05-07 04:48:23 +03:00
Alexey Milovidov
7d93734f54
gcd and lcm for big integers
2021-05-07 03:00:26 +03:00
Alexey Milovidov
0e39d3a589
Fix error
2021-05-07 00:04:47 +03:00
Alexey Milovidov
f5011094c3
Little better
2021-05-06 19:53:22 +03:00
Alexey Milovidov
5025ac7147
Minor edits
2021-05-06 19:35:08 +03:00
Alexey Milovidov
29f1a87016
Simplification
2021-05-06 19:16:31 +03:00
Alexey Milovidov
9f379918ea
Fix error in wide_integer implementation
2021-05-06 03:06:24 +03:00
Alexey Milovidov
1ec524d7c8
Add more tests
2021-05-06 00:20:55 +03:00
Alexey Milovidov
113424d78e
Fixed error; add a test
2021-05-05 23:56:44 +03:00
Alexey Milovidov
fd4f214e43
Fix error
2021-05-05 23:04:15 +03:00
Alexey Milovidov
8940677bf2
Fix wrong code (amend)
2021-05-05 20:25:53 +03:00
Alexey Milovidov
f7114fddf6
Fix error in wide integer <-> integer conversions
2021-05-05 14:53:40 +03:00
Alexey Milovidov
e4e2bacf70
Fix error
2021-05-05 14:16:06 +03:00
Alexey Milovidov
75feb0c599
Fix clang-tidy
2021-05-05 13:37:14 +03:00
Alexey Milovidov
71a34ab098
Fix clang-tidy
2021-05-05 13:36:54 +03:00
Alexey Milovidov
54fb40c041
Fix OpenTelemetry
2021-05-05 01:42:14 +03:00
Alexey Milovidov
d585cfbe46
Addition to Remove unused obsolete code
2021-05-04 22:59:31 +03:00
Alexey Milovidov
c4723c0a4c
Remove unused obsolete code
2021-05-04 22:59:30 +03:00
Alexey Milovidov
9c9ee30484
Addition to Remove unused obsolete code
2021-05-04 22:58:34 +03:00
Alexey Milovidov
617a58b857
Remove unused obsolete code
2021-05-04 20:43:23 +03:00
Alexey Milovidov
86169cc36e
Merge branch 'master' into normalize-bigint
2021-05-04 14:53:42 +03:00
Alexey Milovidov
43bd37b6cc
Fix style
2021-05-04 02:46:11 +03:00
Alexey Milovidov
02ce9cc725
Untangle UUID
2021-05-04 01:46:51 +03:00
Alexey Milovidov
2375b0503f
Add comment
2021-05-03 23:08:56 +03:00
Alexey Milovidov
0677787d90
Fix abysmally low performance
2021-05-03 22:56:40 +03:00
Mikhail Filimonov
25b9d26a47
Allow main log channel to be less verbose than other log channels
2021-05-03 18:29:50 +02:00
filimonov
557afc86f4
Ability to configure the log level for every log channel (main log, error log, stdout, syslog) individually.
2021-05-03 15:29:54 +02:00
Alexey Milovidov
eaa8f922b2
Fix errors, add a test
2021-05-03 00:52:59 +03:00
Azat Khuzhin
5ff78fb297
replxx readline compatibility
...
- By default M-BACKSPACE is KILL_TO_WHITESPACE_ON_LEFT, while in
readline it is backward-kill-word, so use KILL_TO_BEGINING_OF_WORD
instead.
- By default C-w is KILL_TO_BEGINING_OF_WORD, while in readline it is
unix-word-rubout, so use KILL_TO_WHITESPACE_ON_LEFT instead.
2021-05-02 23:26:42 +03:00
Alexey Milovidov
1fda866881
Merge branch 'master' into normalize-bigint
2021-05-02 21:24:45 +03:00
alexey-milovidov
37f44ca7e8
Merge pull request #23776 from ClickHouse/pvs-workaround
...
Workaround for PVS-Studio
2021-05-01 11:58:50 +03:00
Maksim Kita
9c808c4944
Merge pull request #23786 from kitaisreal/add-examples-folder-filter-to-ya-make-in
...
Add examples folder filter to ya.make.in
2021-04-30 15:27:54 +03:00
alexey-milovidov
dd31634ba4
Merge pull request #23746 from oxidecomputer/master
...
Adds support for building on Solaris-derived systems
2021-04-30 13:15:52 +03:00
Maksim Kita
318c4bb80d
Add examples folder filter to ya.make.in
2021-04-30 11:25:52 +03:00
Alexey Milovidov
631711194b
Workaround for PVS-Studio
2021-04-29 22:51:59 +03:00
Benjamin Naecker
7b085abdb1
fixes typo in pcg_detail namespace
2021-04-29 11:07:25 -07:00
Maksim Kita
0d0a14a925
Poco::Timespan reference fix
2021-04-29 19:11:20 +03:00
Benjamin Naecker
57fd59b73b
Adds support for building on Solaris-derived systems
...
This commit adds a number of changes to platform-detection and
compile-time directives required to support building ClickHouse on
Solaris-derived systems, most notably illumos.
2021-04-28 16:32:41 -07:00
Alexey Milovidov
649550c5ab
Attempt to normalize big integers
2021-04-25 12:30:43 +03:00
Alexey Milovidov
8f01af62d9
Merge branch 'master' into normalize-bigint
2021-04-25 06:57:44 +03:00
Alexey Milovidov
4ff812db7f
Maybe better support for paths with whitespaces
2021-04-24 22:47:52 +03:00
tavplubix
bef0ab182e
Merge branch 'master' into fix_prewhere_in_materialize_mysql
2021-04-20 15:38:48 +03:00
Azat Khuzhin
2561a67fd8
Replace !__clang__ with !defined(__clang) to fix gcc builds
...
$ gg 'if !__clang__' | cut -d: -f1 | sort -u | xargs sed -i 's/#if !__clang__/#if !defined(__clang__)/g'
2021-04-18 23:37:50 +03:00
Alexander Tokmakov
3b4bd18809
fix prewhere in materialize mysql
2021-04-16 18:51:27 +03:00
changvvb
4eee2d0977
Merge branch 'master' of https://github.com/ClickHouse/ClickHouse into support-apple-m1
2021-04-15 22:54:26 +08:00
Azat Khuzhin
8ccc61b3bf
Block all memory tracking limits in SCOPE_EXIT_*SAFE
2021-04-14 23:38:41 +03:00
Maksim Kita
0cfe018fd4
Moved BorrowedObjectPool to common
2021-04-13 23:15:22 +03:00
Ivan
495c6e03aa
Replace all Context references with std::weak_ptr ( #22297 )
...
* Replace all Context references with std::weak_ptr
* Fix shared context captured by value
* Fix build
* Fix Context with named sessions
* Fix copy context
* Fix gcc build
* Merge with master and fix build
* Fix gcc-9 build
2021-04-11 02:33:54 +03:00
changvvb
03a2ba315b
Merge branch 'master' of https://github.com/ClickHouse/ClickHouse into support-apple-m1
2021-04-10 21:31:38 +08:00
Denis Glazachev
e8464d61f1
Fix vanilla GCC compilation in macOS
2021-04-09 04:28:24 +04:00
changvvb
b070090ca7
Merge branch 'master' of https://github.com/ClickHouse/ClickHouse into support-apple-m1
2021-04-08 18:11:16 +08:00
Azat Khuzhin
9394e6e5ed
Add SCOPE_EXIT_SAFE/SCOPE_EXIT_MEMORY_SAFE helpers
2021-04-06 21:10:37 +03:00
alesapin
86a843bb51
Merge pull request #21509 from kssenii/library-bridge
...
clickhouse-library-bridge for library dictionary source
2021-04-06 12:26:08 +03:00
changvvb
1f8bd034a3
Merge branch 'master' of https://github.com/ClickHouse/ClickHouse into support-apple-m1
2021-04-06 15:55:03 +08:00
kssenii
9dba529494
Merge branch 'master' of https://github.com/ClickHouse/ClickHouse into library-bridge
2021-04-05 13:14:51 +00:00
kssenii
99f0b08ac3
Merge branch 'master' of https://github.com/ClickHouse/ClickHouse into replicas-shards-for-mysql-and-postgres
2021-04-01 13:48:33 +00:00
kssenii
2c70183652
Fix settings
2021-04-01 11:41:22 +00:00
kssenii
747967a9bb
Better
2021-04-01 10:27:24 +00:00
Alexey Milovidov
7589a014f9
Better fix
2021-04-01 03:44:02 +03:00
kssenii
4e849f3b77
Less logging
2021-03-31 14:06:24 +00:00
kssenii
ba5ddd5c32
Do not parse replicas in PoolWithFailover
2021-03-31 14:03:52 +00:00
kssenii
ce05087b1b
Merge branch 'master' of https://github.com/ClickHouse/ClickHouse into replicas-shards-for-mysql-and-postgres
2021-03-30 17:27:10 +00:00
Alexey Milovidov
de3b452d7a
Remove useless code from setTerminalEcho #20334
2021-03-30 00:39:38 +03:00
Alexey Milovidov
b005081103
Update libdivide to the latest master (2)
2021-03-30 00:37:27 +03:00
Maksim Kita
6fb444f732
Merge pull request #20184 from nvartolomei/nv/macos-shared
...
Fix macOS shared lib build
2021-03-29 18:25:43 +03:00
Alexey Milovidov
7fcae60466
Merge branch 'master' into to-start-of-interval-hour-align
2021-03-29 05:42:00 +03:00
kssenii
d409f089fc
Fix split build
2021-03-28 14:56:02 +00:00
kssenii
1bd1a705ce
Fix clang tidy
2021-03-28 12:45:49 +00:00
kssenii
0a66f11f69
Fix style, fix build
2021-03-28 10:27:37 +00:00
kssenii
c17748a0ba
Add proper settings
2021-03-27 21:57:35 +00:00
kssenii
ef537b802f
Better comments
2021-03-27 21:10:44 +00:00
kssenii
95e8a8b9f0
Support shards
2021-03-27 14:40:07 +00:00
kssenii
ae868208c2
Use pool with failover in mysql storage
2021-03-27 14:39:45 +00:00
changvvb
5e07551d17
Merge branch 'master' of https://github.com/ClickHouse/ClickHouse into support-apple-m1
2021-03-26 16:57:26 +08:00
Alexey Milovidov
ea3cf5c0a7
Fix typo
2021-03-24 22:48:39 +03:00
Alexey Milovidov
b610afe771
Another fix
2021-03-24 22:40:45 +03:00
Alexey Milovidov
5a2f2e0cc8
Change behaviour of toStartOfInterval
in backward incompatible way
2021-03-24 01:53:19 +03:00
kssenii
50ae954a85
Fix
2021-03-23 05:48:21 +00:00
Alexey Milovidov
3952a8e976
Fix UBSan report in addMonths
2021-03-22 23:42:09 +03:00
changvvb
b4e92f6b12
Merge branch 'master' of https://github.com/ClickHouse/ClickHouse into support-apple-m1
2021-03-19 13:52:09 +08:00
kssenii
34dea63248
Merge branch 'master' of https://github.com/ClickHouse/ClickHouse into library-bridge
2021-03-17 13:32:43 +00:00
alexey-milovidov
d02726bcac
Merge pull request #9404 from Enmk/DateTime64_extended_range
...
Date time64 extended range
2021-03-17 11:06:03 +03:00
Alexey Milovidov
de091114f3
Fix UBSan report
2021-03-16 15:22:52 +03:00
Alexey Milovidov
eadf0248d0
Build fixes
2021-03-16 14:07:53 +03:00
changvvb
bba600d558
Merge branch 'master' of https://github.com/ClickHouse/ClickHouse into support-apple-m1
2021-03-16 13:26:00 +08:00
Alexey Milovidov
c1a2745bfb
Add one more variant to memcpy benchmark
2021-03-16 00:04:03 +03:00
Alexey Milovidov
f48bf2aaba
Fix issue
2021-03-15 23:29:35 +03:00
Alexey Milovidov
671395e8c8
Most likely improve performance
2021-03-15 22:23:27 +03:00
Alexey Milovidov
845f4afbf4
Fix parsing of pre-epoch time
2021-03-15 21:09:05 +03:00
Alexey Milovidov
badd5165da
Fix UBSan report in rounding to years intervals
2021-03-15 20:36:49 +03:00
kssenii
8688ae9346
Merge branch 'master' of https://github.com/ClickHouse/ClickHouse into library-bridge
2021-03-14 19:32:21 +00:00
alexey-milovidov
53e21443eb
Merge branch 'master' into DateTime64_extended_range
2021-03-14 12:27:17 +03:00
Alexey Milovidov
1606c7e3f3
Fix typo
2021-03-14 12:24:17 +03:00
Alexey Milovidov
bab924620a
Add comments and documentation
2021-03-14 00:53:00 +03:00
Alexey Milovidov
a1ebd52d09
Add comments and documentation
2021-03-14 00:51:13 +03:00
Alexey Milovidov
32e66baa0a
Add comments and documentation
2021-03-14 00:48:44 +03:00
Alexey Milovidov
b4cae2c858
Add TODO
2021-03-14 00:48:08 +03:00
Alexey Milovidov
36a41220d3
Add comments and documentation
2021-03-14 00:46:47 +03:00
Alexey Milovidov
37cc2fe977
Use custom memcpy only for AArch64
2021-03-13 22:39:10 +03:00
Alexey Milovidov
a446612e8a
Remove currently unused code
2021-03-13 10:39:43 +03:00
Alexey Milovidov
6d91881f6a
Remove currently unused code
2021-03-13 10:38:35 +03:00
Alexey Milovidov
e8919c49fb
Merge branch 'master' into replace-memcpy
2021-03-13 09:39:58 +03:00
kssenii
5d953a4b86
Better
2021-03-12 21:48:52 +00:00
kssenii
323fb54a8e
Fix split build finally
2021-03-12 21:12:34 +00:00
Nikita Mikhaylov
e234990cf6
Merge pull request #19257 from nikitamikhaylov/geometry_functions
...
Merging geometry functions
2021-03-12 17:05:24 +03:00
changvvb
fcb238715b
Support apple m1
2021-03-12 01:12:52 +08:00
Nikita Mikhailov
e78fc3109c
better ubsan testing
2021-03-11 15:08:18 +03:00
Yatsishin Ilya
abbf4b01c2
Merge remote-tracking branch 'origin/master' into fixes-clang-12-cmake-3.19
2021-03-11 09:44:30 +03:00
Yatsishin Ilya
c2760f6388
readpassphrase mute recursion in macro expansion
2021-03-10 18:05:24 +03:00
Yatsishin Ilya
7b69ef92be
gcc old cast check failed
2021-03-10 18:04:34 +03:00
Yatsishin Ilya
eb0e972620
implicit cast to disable warning
2021-03-10 12:01:03 +03:00
Alexey Milovidov
8619665ef2
Remove AVX
2021-03-10 10:04:33 +03:00
Yatsishin Ilya
71d745b4ec
implicit const conversion
2021-03-09 17:31:54 +03:00
Alexey Milovidov
7664a3d53e
Fix MSan
2021-03-09 01:29:32 +03:00
Alexey Milovidov
e02de2355e
Remove useless files
2021-03-08 13:22:17 +03:00
Alexey Milovidov
3fb5b247ed
Evaluate another memcpy
2021-03-08 13:19:25 +03:00
Alexey Milovidov
f0342eda9c
Add experimental memcpy implementation
2021-03-08 13:05:18 +03:00
Alexey Milovidov
da32a617b2
Merge branch 'jart-memcpy' into replace-memcpy
2021-03-08 12:15:49 +03:00
Alexey Milovidov
2c86bc4ea3
Addition to prev. revision
2021-03-08 10:00:54 +03:00
Alexey Milovidov
1200d9d9c5
Range checks and monotonicity
2021-03-07 10:10:37 +03:00
Alexey Milovidov
7052ecd446
Fix error
2021-03-07 09:30:52 +03:00
Alexey Milovidov
1bb62f578b
Unit tests passing
2021-03-07 04:10:38 +03:00
Alexey Milovidov
8271cec093
Fix error
2021-03-07 02:36:24 +03:00
Alexey Milovidov
d406999e8f
Remove debug output
2021-03-07 01:36:48 +03:00
Alexey Milovidov
0dbadc8d8e
Fix error
2021-03-07 01:35:23 +03:00
Alexey Milovidov
8d5d1b76fb
Fix error
2021-03-07 00:36:29 +03:00
Alexey Milovidov
d276fac135
Support negative time_t in more functions
2021-03-05 05:04:23 +03:00
Alexey Milovidov
738d106874
Support negative time_t in more functions
2021-03-05 05:03:55 +03:00
Alexey Milovidov
ecee81b714
Fix clang-tidy
2021-03-05 04:50:16 +03:00
Alexey Milovidov
790aa8697c
Fix typos
2021-03-05 04:47:50 +03:00
Alexey Milovidov
1722978c2b
Comments and corrections
2021-03-05 04:45:12 +03:00
Alexey Milovidov
7cc471f9b9
Simplify code
2021-03-05 04:22:12 +03:00
Haavard Kvaalen
efa94c5735
Fix use after free in mysqlxx::Pool::tryGet()
...
tryGet() created an Entry object that referenced a Connection, but then
deleted the Connection just before the Entry went out of scope.
2021-03-04 16:51:27 +01:00
Alexey Milovidov
ed492ccf5d
Fix Africa/Juba
2021-03-04 05:36:36 +03:00
Alexey Milovidov
b9a8509f79
Adjustments
2021-03-04 05:18:17 +03:00
Alexey Milovidov
31010624d6
Attempt to simplify code
2021-03-04 03:35:23 +03:00
Alexey Milovidov
4f08539754
Remove strange code
2021-03-04 03:01:08 +03:00
Alexey Milovidov
1096fc328a
Make some tests automated
2021-03-04 02:11:27 +03:00
Alexey Milovidov
ffc39574f1
Removed very old example (for jemalloc performance regression)
2021-03-04 02:04:01 +03:00
Alexey Milovidov
2632b568ae
Move tests to appropriate place
2021-03-04 01:34:30 +03:00
Alexey Milovidov
51d51e4748
Return private
2021-03-04 00:44:58 +03:00
Alexey Milovidov
fdc00beb77
Whitespaces
2021-03-03 23:56:59 +03:00
Alexey Milovidov
6f5877abdf
Fix build after merge with master
2021-03-03 23:53:52 +03:00
Alexey Milovidov
4e8239e098
Merge branch 'master' into DateTime64_extended_range
2021-03-03 23:43:20 +03:00
Alexey Milovidov
b1b3db09d7
Remove commented out code
2021-03-03 23:34:15 +03:00
Alexey Milovidov
ed0099a113
Maybe unused condition
2021-03-03 23:24:56 +03:00
Alexey Milovidov
aaef0c5ebd
Fix build
2021-03-03 23:19:26 +03:00
Alexey Milovidov
cf0912ba02
Remove unused field
2021-03-03 23:14:33 +03:00
alexey-milovidov
3e19f4a00f
Update DateLUTImpl.h
2021-03-03 23:09:59 +03:00
alexey-milovidov
0889e0da87
Update DateLUTImpl.h
2021-03-03 22:52:07 +03:00
alexey-milovidov
2f23f1b123
Update DateLUTImpl.h
2021-03-03 22:49:20 +03:00
alexey-milovidov
80c17d5537
Update DateLUTImpl.cpp
2021-03-03 22:41:10 +03:00
alexey-milovidov
e412bcb490
Update DateLUTImpl.cpp
2021-03-03 22:30:12 +03:00
alexey-milovidov
04672a4365
Update DateLUTImpl.cpp
2021-03-03 22:29:26 +03:00
Alexey Milovidov
aecdadd02e
Add missing files
2021-03-03 02:33:17 +03:00
Alexey Milovidov
d1b3258ae7
Try without AVX
2021-03-03 00:16:34 +03:00
Alexey Milovidov
50c62c3b4c
Add memcpy implementation from @jart
2021-03-02 22:12:30 +03:00
alexey-milovidov
3bd180c416
Merge pull request #20149 from keen-wolf/timezone_about
...
fix toMinute function to handle special timezone
2021-02-28 21:53:51 +03:00
keenwolf
303c389b36
change the time_t to unsigned to handle properly the start date of 1970-01-01
2021-02-28 18:11:54 +08:00
Alexander Kazakov
63b95c7451
MySQL dictionary source: A mechanism for retrying unexpected connection loss during communication with mysql server ( #21237 )
...
* Added a new type of Exception
for better recognition of connection failures
* Added more logging for mysql communication
* Retries on connection loss during query.
Make MySQL dictionary source resilient to unexpected loss of connection
during querying MySQL. This behavior is controlled with
".fail_on_connection_loss" config parameter, which defaults to false.
* Stripped some debugging leftover garbage
* Minor followup corrections
* Corrections after PR comments
* Yet more fixes
2021-02-27 11:18:28 +03:00
Alexander Kazakov
66f603512c
A followup correction to #19998 ( #21221 )
2021-02-26 11:42:37 +03:00
Alexander Kazakov
4bcaed98d8
Added "opt_reconnect" parameter to config for controlling MYSQL_OPT_RECONNECT option ( #19998 )
...
* Support for MYSQL_OPT_RECONNECT option
It can now be controlled by .opt_reconnect = {true|false} parameter in
the mysql replica config section
2021-02-26 09:49:49 +03:00
Maksim Kita
63173eebdb
Merge pull request #21088 from azat/__has_feature-gcc-fix
...
Fix __has_feature macros under gcc
2021-02-25 18:34:14 +03:00
Nikolai Kochetov
3cda69feaf
Merge pull request #20632 from ClickHouse/akz/mysqlxx-randomize-replicas
...
mysqlxx::PoolWithFailover: Randomize list of same-priority replicas
2021-02-25 13:11:41 +03:00
alexey-milovidov
d5757c67e6
Update DateLUTImpl.h
2021-02-24 17:09:27 +02:00
alexey-milovidov
b8b916008c
Update DateLUTImpl.h
2021-02-24 17:09:27 +02:00
Vasily Nemkov
d321c13cbf
Fixed special build
2021-02-24 17:08:43 +02:00
Vasily Nemkov
7a53daaefd
Fixed issues reported by PVS-Studio and Clang11/GCC10
2021-02-24 17:08:43 +02:00
Vasily Nemkov
4fcc23ec9a
Fixed build for GCC-10
2021-02-24 17:08:43 +02: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
Alexander Kazakov
196d454114
Initialize random engine with clock and thread_id
...
Thread-safe and fairly descent approach in our case
2021-02-24 14:55:16 +03:00
Alexander Kazakov
deb566a40b
Resorted from std::random_device to std::rand()
2021-02-24 11:48:04 +03:00
Azat Khuzhin
810023a65c
Do not undefine __has_feature (may break c++ headers)
...
If the order of <common/defines.h> and c++ header will be wrong the
compilation will be broken.
v2: rename __ch_has_feature to ch_has_feature to fix -Wreserved-id-macro
v3: do not fallback to 0
2021-02-23 19:46:47 +03:00
Azat Khuzhin
8ab578065a
Fix __has_feature macros under gcc
...
__has_feature supported only by clang.
But libcxx/libcxxabi overrides it to 0:
$ fgrep -r 'define __has_feature' contrib/libcxx*
contrib/libcxx/include/__config:#define __has_feature(__x) 0
contrib/libcxxabi/src/demangle/DemangleConfig.h:#define __has_feature(x) 0
Thus the checks for __has_feature will be wrong, undefine it again to
avoid such issues.
This will also fix building with sanitizers under gcc (before this patch
BOOST_USE_UCONTEXT wasn't set for sanitizers).
2021-02-23 19:39:34 +03:00
Alexey Milovidov
d2a9e5842a
Fix wrong formatting of overflowed DateTime64
2021-02-21 21:01:46 +03:00
Alexey Milovidov
9cb972e9ed
Fix UBSan report in Decimal arithmetic #19432
2021-02-21 13:23:18 +03:00
alexey-milovidov
e8583ddfe2
Update BaseDaemon.cpp
2021-02-20 09:10:15 +03:00
Azat Khuzhin
7474a7e3ca
Increase buffer for uncaught exception / std::terminate
...
Use PIPE_BUF over some magic number 1024 in terminate_handler, since
according to pipe(7):
PIPE_BUF
POSIX.1 says that write(2)s of less than PIPE_BUF bytes must be atomic
Also note that 1024, is too small, especially for C++ stacktraces (and
especially for debug builds, that contains lots of non-inlined helpers
for various ptrs).
2021-02-19 22:45:06 +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 Kazakov
0296d7d026
Added some explanations on randomization
2021-02-17 21:51:05 +03:00
Alexander Kazakov
acb5fb8179
Randomly shuffle replicas withing the same priority
2021-02-17 20:58:04 +03:00
alexey-milovidov
bde4da0ff0
Merge pull request #20465 from azat/write-abnormal-server-termination-fixes
...
Fix abnormal server terminations due to write failures
2021-02-15 00:05:48 +03:00
Azat Khuzhin
06e8065ee6
Add missing sync of underlying files
2021-02-13 13:19:51 +03:00
Ilya Yatsishin
8ff458a2bf
Merge pull request #20459 from ClickHouse/decimal-comparison-ubsan
2021-02-13 12:34:40 +03:00
Alexey Milovidov
c760d5224d
Suppress UBSan report in Decimal comparison
2021-02-13 03:56:38 +03:00
Alexey Milovidov
1546f5bcb9
Suppress UBSan report in Decimal comparison
2021-02-13 03:54:38 +03:00
Alexey Milovidov
edd5844bed
Print stack trace on SIGTRAP
2021-02-13 00:29:47 +03:00
alexey-milovidov
4e32dbd024
Merge pull request #19317 from abyss7/dwarf-folly
...
Print inline frames for fatal stacktraces
2021-02-12 02:38:50 +03:00
Ivan
be831d09f7
Update Pytest check ( #18972 )
...
* [WIP]
* Update skip-list
* Update ci_config.json
* Do not sync inserts for test
* Fix more tests
* Fix another test
* Enable one more test
* More fixed tests
* More test fixes
* Do not absolutize server path for now
* More test fixes
* Unset CLICKHOUSE_LOG_COMMENT where necessary
* Remove debugging set -e
* Fix more tests
* Fix test reference
* Fix style check
2021-02-10 21:09:13 +03:00
Ivan Lezhankin
a287443438
Merge remote-tracking branch 'upstream/master' into dwarf-folly
2021-02-08 18:36:41 +03:00
Nicolae Vartolomei
479b45d772
Fix linker flags for shared linking on macOS
...
This combination now works: `-DUSE_STATIC_LIBRARIES=0 -DSPLIT_SHARED_LIBRARIES=1`.
Without `SPLIT_SHARED_LIBRARIES` it is still failing.
2021-02-07 14:58:52 +00:00
keenwolf
610798aa48
fix the toMinute bug which will cause toDateTime or toString printing wrong time
2021-02-06 15:32:49 +08:00
alexey-milovidov
867f5a8975
Merge pull request #20029 from ClickHouse/remove-useless-code-5
...
Remove useless code
2021-02-03 21:06:43 +03:00
Nikolai Kochetov
c39c965612
Merge pull request #19962 from keen-wolf/timezoneOffset
...
Implement the timezoneOffset function
2021-02-03 20:37:34 +03:00
Alexey Milovidov
02da869d10
Remove useless code
2021-02-03 12:46:41 +03:00
Alexey Milovidov
940b337eec
Remove useless files
2021-02-03 10:03:32 +03:00
Alexey Milovidov
f8592f4539
Remove useless files
2021-02-03 10:03:13 +03:00
Alexey Milovidov
191389d040
Fix some of the issues found by Coverity
2021-02-02 22:08:32 +03:00
Alexey Milovidov
12485eee6b
Fix some of the issues found by Coverity
2021-02-02 22:07:23 +03:00
keenwolf
9beb7689cc
add comments and update test cases.
2021-02-02 23:35:45 +08:00
keenwolf
d251807ea4
add function timezoneOffset
2021-02-02 11:01:20 +08:00
Alexey Milovidov
7b8589dbde
Merge branch 'master' into utf8mb4-in-mysql-client
2021-01-31 01:37:27 +03:00
alexey-milovidov
8d2a169e8d
Merge pull request #19821 from qoega/fix-msan-1
...
Fix msan warnings in cyrus-sasl and musl
2021-01-30 10:56:12 +03:00
Yatsishin Ilya
f8ae63995e
Fix msan warnings
2021-01-29 19:11:50 +03:00
Alexey Milovidov
f7fffe173c
Set charset to utf8mb4 in mariadb-connector
2021-01-29 10:57:22 +03:00
Alexey Milovidov
eb0473c3f9
Fix UBSan report in "round"
2021-01-29 04:03:38 +03:00
Ivan
5dfe1c98e2
Update BaseDaemon.cpp
2021-01-27 16:25:46 +03:00
Maksim Kita
bd81f43ecb
Merge pull request #19672 from ClickHouse/bigint-remove-old-code
...
Remove old code for BigInt.
2021-01-27 11:28:45 +03:00
Alexey Milovidov
093108bf81
Normalize BigInt implementation
2021-01-27 03:54:57 +03:00
Alexey Milovidov
f3929b151a
Remove even more code
2021-01-26 22:04:03 +03:00
Azat Khuzhin
f4a4d33c2d
Suppress UBsan reports in addYears()
...
https://clickhouse-test-reports.s3.yandex.net/19528/1c364b6ee3a44487529954cf2792e615f7de0f82/fuzzer_ubsan/report.html#fail1
2021-01-26 01:12:40 +03:00
tavplubix
9fc1eba0bc
Update DateLUTImpl.h
2021-01-25 12:40:49 +03:00
alexey-milovidov
77af612bc5
Merge pull request #19466 from azat/UBsan-report-fixes
...
UBsan report fixes (arraySlice, addMinutes/addHours/addWeeks/addDays, sumWithOverflow(Decimal))
2021-01-24 22:27:15 +03:00
Azat Khuzhin
cb30a02540
Fix UBsan report in addDays(INT64_MAX)
...
https://clickhouse-test-reports.s3.yandex.net/19466/df53438a66ee95de790b60d35f36eca986590027/fuzzer_ubsan/report.html#fail1
2021-01-24 13:51:05 +03:00
Alexey Milovidov
505898747e
Fix buffer overflow in DateLUT
2021-01-23 01:58:41 +03:00
alexey-milovidov
303db08231
Merge pull request #19369 from filimonov/kafka_for_arm64
...
Kafka for arm64
2021-01-23 01:52:07 +03:00
Mikhail Filimonov
066fbfff0e
librdkafka support for arm64
2021-01-21 16:04:55 +01:00
Alexey Milovidov
4968f1733e
Annotations for DateLUT
2021-01-21 15:01:24 +03:00
Alexander Tokmakov
6847fdf772
fix
2021-01-20 14:12:33 +03:00
Ivan Lezhankin
3fb50dfa1b
Initial implementation of inline frames
2021-01-19 15:34:27 +03:00
Alexander Tokmakov
e2467427d1
Merge branch 'master' into update_cassandra
2021-01-19 14:10:15 +03:00
Alexey Milovidov
98a8a20b70
Fix MSan error in rocksdb #19213
2021-01-17 21:30:02 +03:00
Alexander Tokmakov
e57e242482
fix
2021-01-16 22:56:07 +03:00
Alexander Tokmakov
ff6c3c75c2
add protection from unsafe allocations
2021-01-12 18:41:24 +03:00
alexey-milovidov
a55260fa5c
Merge pull request #18871 from azat/fix-integrity-check
...
Fix integrity check
2021-01-08 22:32:39 +03:00
alexey-milovidov
4a54916733
Merge pull request #18858 from ClickHouse/better-strsignal
...
Import strsignal from Musl
2021-01-08 22:26:00 +03:00
Azat Khuzhin
6dba945a2e
untrap setenv() call (used for timezone)
...
This will also fix integrity check (#18811 ), the reason it does not pops
up on CI during PR testing because CI does not set
YANDEX_OFFICIAL_BUILD, while it does set it for commits merged into
upstream commits, and hence once it was merged the special build was
failed.
Follow-up for: #16366
2021-01-08 15:26:35 +03:00
Alexey Milovidov
10ea06edad
Import strsignal from Musl
2021-01-08 08:09:30 +03:00
alexey-milovidov
98bd7fb653
Merge branch 'master' into better-kill
2021-01-08 07:27:00 +03:00
Alexey Milovidov
32d8785a26
Better kill #18847
2021-01-07 21:36:38 +03:00
Alexey Milovidov
6f481d7512
Add integrity checks for ClickHouse binary
2021-01-07 05:56:57 +03:00
Azat Khuzhin
d7fb61dce4
Use sigdescr_np() over sys_siglist (fixes glibc 2.32+ unbundled build)
...
glibc 2.32 [1]:
- The functions sigabbrev_np and sigdescr_np have been added
- They should be used instead of sys_siglist or sys_sigabbrev and they
are both thread and async-signal safe. These functions are GNU
extensions.
[1]: https://sourceware.org/pipermail/libc-announce/2020/000029.html
2021-01-06 00:17:25 +03:00
Alexey Milovidov
98687ff8f4
Merge branch 'master' into harmful
2020-12-31 02:25:28 +03:00