Mike Kot
9920a52c51
use std::lerp, constexpr hex.h
2023-03-07 22:50:17 +00:00
Azat Khuzhin
8cc41b7f41
Check return value of ::close()
...
Note, that according close(2), EINTR should not be retriable for close()
Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
2023-02-07 11:28:22 +01:00
Alexander Tokmakov
70d1adfe4b
Better formatting for exception messages ( #45449 )
...
* save format string for NetException
* format exceptions
* format exceptions 2
* format exceptions 3
* format exceptions 4
* format exceptions 5
* format exceptions 6
* fix
* format exceptions 7
* format exceptions 8
* Update MergeTreeIndexGin.cpp
* Update AggregateFunctionMap.cpp
* Update AggregateFunctionMap.cpp
* fix
2023-01-24 00:13:58 +03:00
Antonio Andelic
e363e27eef
Merge pull request #42532 from ClickHouse/fix-data-race
...
Fix `KeeperTCPHandler` data race
2022-10-24 09:14:34 +02:00
Azat Khuzhin
15bcd6250a
Fix -Wshorten-64-to-32 for darwin builds
...
Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
2022-10-21 13:25:42 +02:00
Azat Khuzhin
4e76629aaf
Fixes for -Wshorten-64-to-32
...
- lots of static_cast
- add safe_cast
- types adjustments
- config
- IStorage::read/watch
- ...
- some TODO's (to convert types in future)
P.S. That was quite a journey...
v2: fixes after rebase
v3: fix conflicts after #42308 merged
Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
2022-10-21 13:25:19 +02:00
Antonio Andelic
13480f940b
Handle 4LW correctly
2022-10-21 07:29:00 +00:00
Antonio Andelic
73e16ad55a
Fix KeeperTCPHandler data race
2022-10-21 07:29:00 +00:00
Amos Bird
4a5e4274f0
base should not depend on Common
2022-04-29 10:26:35 +08:00
Antonio Andelic
cd548aeb30
Refactor test for multiple cluster size
2022-04-19 08:08:36 +00:00
Antonio Andelic
6c3bf0a5d3
Format files
2022-04-19 08:08:36 +00:00
Antonio Andelic
ff2ebe113c
WIP
2022-04-19 08:08:35 +00:00
Azat Khuzhin
ff0e46c394
clickhouse-keeper: finish session on client EOF (fixes heap-use-after-free)
...
CI founds [1]:
WARNING: ThreadSanitizer: heap-use-after-free (pid=1)
Read of size 8 at 0x7b48001e0088 by thread T7 (mutexes: write M2588):
...
1 DB::KeeperTCPHandler::runImpl()::$_0::operator()() const build_docker/../src/Server/KeeperTCPHandler.cpp:384:14 (clickhouse+0x194f974f)
...
8 DB::KeeperDispatcher::setResponse() build_docker/../src/Coordination/KeeperDispatcher.cpp:222:9 (clickhouse+0x1999de82)
9 DB::KeeperDispatcher::responseThread() build_docker/../src/Coordination/KeeperDispatcher.cpp:161:18 (clickhouse+0x1999d7a7)
10 DB::KeeperDispatcher::initialize()::$_1::operator()() const build_docker/../src/Coordination/KeeperDispatcher.cpp:273:54 (clickhouse+0x199a55d1)
Previous write of size 8 at 0x7b48001e0088 by thread T3:
0 operator delete(void*, unsigned long) <null> (clickhouse+0xa0dad50)
1 DB::KeeperTCPHandler::~KeeperTCPHandler() build_docker/../src/Server/KeeperTCPHandler.cpp:648:1 (clickhouse+0x194f8ee6)
[1]: https://s3.amazonaws.com/clickhouse-test-reports/35772/38873d726d22b15d4c5a284410956927b2e2f95f/integration_tests__thread__actions__[4/4].html
Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
2022-03-31 09:31:34 +03:00
Azat Khuzhin
38873d726d
clickhouse-keeper: fix implementation of server with poll()
...
Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
2022-03-30 21:30:12 +03:00
Azat Khuzhin
9820230e95
clickhouse-keeper: correctly handle closed client connection
...
This will avoid noisy message like:
DB::Exception: Cannot read all data. Bytes read: 0. Bytes expected: 4.
Signed-off-by: Azat Khuzhin <a.khuzhin@semrush.com>
2022-03-30 20:29:04 +03:00
alesapin
33ff2f76e5
Merge branch 'master' into standalone_keeper_build
2022-03-11 13:58:44 +01:00
alesapin
0eb7d28192
Building small keeper binary
2022-03-03 21:27:46 +01:00
zhanglistar
9ee0d2c8a0
keeper atomic stat
2022-03-03 14:30:22 +08:00
alesapin
3d325aacf6
Merge branch 'master' into better_hashmap
2022-01-19 12:31:23 +03:00
alesapin
4fb8761a22
Merge branch 'master' into better_hashmap
2022-01-17 15:51:50 +03:00
alesapin
b2271cc2d9
Merge pull request #33288 from JackyWoo/add_lower_bound_session_timeout_to_keeper
...
Add lower bound session timeout to keeper
2022-01-17 14:06:15 +03:00
alesapin
ec6840f49c
Make ZooKeeper client better interpret keeper server connection reject
2022-01-13 17:12:10 +03:00
alesapin
f8114126ed
Use HashMap and arena with free lists for keeper
2021-12-30 19:21:49 +03:00
JackyWoo
569ce62e8d
use session_timeout as session timeout uper bound
2021-12-30 17:18:51 +08:00
JackyWoo
19b5394be8
fix tests
2021-12-30 15:49:48 +08:00
JackyWoo
d35e5f8319
add lower bound session timeout to keeper
2021-12-29 20:59:01 +08:00
JackyWoo
7a19570853
keeper handler should remove operation when response sent
2021-12-21 11:43:14 +08:00
JackyWoo
4c6ad94109
fix ch keeper session timeout doesn't work
2021-11-26 18:17:49 +08:00
alesapin
16f034fe4c
Flush bytes after 4 letter commands
2021-11-23 13:31:10 +03:00
alesapin
5825242a7d
Merge branch 'add_4_letter_words_commands' of github.com:JackyWoo/ClickHouse into JackyWoo_add_4_letter_words_commands
2021-11-22 18:02:22 +03:00
alesapin
35de9e42d9
Merge branch 'master' into add_4_letter_words_commands
2021-11-22 18:02:02 +03:00
alesapin
1cf204c581
Small changes
2021-11-21 15:28:45 +03:00
Alexander Tokmakov
856502fa81
log long operations in Keeper
2021-11-20 20:39:31 +03:00
alesapin
3f8f08e816
Slightly better
2021-11-19 12:30:58 +03:00
alesapin
dcec086573
Small refactoring
2021-11-18 23:17:22 +03:00
JackyWoo
27d50edc59
adjust log output
2021-11-18 15:49:43 +08:00
JackyWoo
007366b506
remove sizeOf method from SnapshotableHashTable
2021-11-18 12:35:32 +08:00
alesapin
5f3eca4cd1
Merge branch 'master' into JackyWoo_add_4_letter_words_commands
2021-11-17 12:59:20 +03:00
JackyWoo
a2f3337ca1
code style change
2021-11-12 20:48:42 +08:00
JackyWoo
1cbe9f6024
fix build error
2021-11-10 10:50:12 +08:00
JackyWoo
c71fb3337f
add more 4lwd commands
2021-11-09 17:39:28 +08:00
alesapin
30ab4b3a7f
Update KeeperTCPHandler.cpp
2021-10-30 16:02:05 +03:00
alesapin
40bffcec3a
Fix error message in Keeper
2021-10-30 15:32:29 +03:00
JackyWoo
694306ee62
add 4lw white list to keeper
2021-10-29 17:54:25 +08:00
JackyWoo
e5b0eedd31
adjust code style for keeper 4lw cmd
2021-10-27 22:26:53 +08:00
JackyWoo
a60663e33d
add 4lw commands to keeper
2021-10-27 20:26:42 +08:00
alesapin
f1fe96e194
Merge branch 'master' into debug_keeper
2021-10-18 10:16:07 +03:00
alesapin
90ff7f05fd
Start keeper asynchronously if has connection to other nodes
2021-10-14 13:21:41 +03:00
Maksim Kita
3d2e1a24d9
Fixed tests
2021-10-14 00:33:18 +03:00
Maksim Kita
04047f76c7
Fixed tests
2021-10-14 00:33:18 +03:00