mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-30 19:42:00 +00:00
ClickHouse® is a real-time analytics DBMS
aa3f4003c8
There was a race condition when issuing a DDL query on a replica just after a new replica was added. If the DDL query is issued after the new replica adds itself to the list of replicas, but before the new replica has finished its recovery, then the first replica adds the new replica to the list of replicas to wait to confirm the query was replicated. Meanwhile, the new replica is still in recovery and applies queries from the /metadata snapshot. When it's done, it bumps its log_ptr without marking the corresponding log entries (if any) as finished. The first replica then waits until distributed_ddl_task_timeout expires and wrongly assumes the query was not replicated. The issue is fixed by remembering the max_log_ptr at the exact point where the replica adds itself to the list of replicas, then mark as finished all queries that happened between that max_log_ptr and the max_log_ptr of the metadata snapshot used in recovery. The bug was randomly observed during a downstream test. It can be reproduced more easily by inserting a sleep of a few seconds at the end of createReplicaNodesInZooKeeper, enough to have time to issue a DDL query on the first replica. |
||
---|---|---|
.github | ||
base | ||
benchmark | ||
cmake | ||
contrib | ||
debian | ||
docker | ||
docs | ||
programs | ||
src | ||
tests | ||
utils | ||
website | ||
.arcignore | ||
.clang-format | ||
.clang-tidy | ||
.editorconfig | ||
.gitattributes | ||
.gitignore | ||
.gitmodules | ||
.potato.yml | ||
.pylintrc | ||
.vimrc | ||
.yamllint | ||
AUTHORS | ||
CHANGELOG.md | ||
CMakeLists.txt | ||
CODE_OF_CONDUCT.md | ||
CONTRIBUTING.md | ||
docker-compose.yml | ||
format_sources | ||
LICENSE | ||
PreLoad.cmake | ||
README.md | ||
release | ||
SECURITY.md | ||
uncrustify.cfg | ||
ya.make |
ClickHouse® is an open-source column-oriented database management system that allows generating analytical data reports in real time.
Useful Links
- Official website has quick high-level overview of ClickHouse on main page.
- Tutorial shows how to set up and query small ClickHouse cluster.
- Documentation provides more in-depth information.
- YouTube channel has a lot of content about ClickHouse in video format.
- Slack and Telegram allow to chat with ClickHouse users in real-time.
- Blog contains various ClickHouse-related articles, as well as announcements and reports about events.
- Code Browser with syntax highlight and navigation.
- Contacts can help to get your questions answered if there are any.