Skip to content

Commit 609a6ad

Browse files
authored
Merge pull request #3203 from ClickHouse/merges
Table part merges documentation.
2 parents 3532606 + 66d6fa2 commit 609a6ad

File tree

14 files changed

+183
-8
lines changed

14 files changed

+183
-8
lines changed

docs/en/concepts/why-clickhouse-is-so-fast.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -13,19 +13,19 @@ From an architectural perspective, databases consist (at least) of a storage lay
1313

1414
## Storage Layer: Concurrent inserts are isolated from each other
1515

16-
In ClickHouse, each table consists of multiple "table parts". A part is created whenever a user inserts data into the table (INSERT statement). A query is always executed against all table parts that exist at the time the query starts.
16+
In ClickHouse, each table consists of multiple "table parts". A [part](/docs/en/parts) is created whenever a user inserts data into the table (INSERT statement). A query is always executed against all table parts that exist at the time the query starts.
1717

18-
To avoid that too many parts accumulate, ClickHouse runs a merge operation in the background which continuously combines multiple (small) parts into a single bigger part.
18+
To avoid that too many parts accumulate, ClickHouse runs a [merge](/docs/en/merges) operation in the background which continuously combines multiple smaller parts into a single bigger part.
1919

20-
This approach has several advantages: On the one hand, individual inserts are "local" in the sense that they do not need to update global, i.e. per-table data structures. As a result, multiple simultaneous inserts need no mutual synchronization or synchronization with existing table data, and thus inserts can be performed almost at the speed of disk I/O.
20+
This approach has several advantages: All data processing can be [offloaded to background part merges](/docs/en/concepts/why-clickhouse-is-so-fast#storage-layer-merge-time-computation), keeping data writes lightweight and highly efficient. Individual inserts are "local" in the sense that they do not need to update global, i.e. per-table data structures. As a result, multiple simultaneous inserts need no mutual synchronization or synchronization with existing table data, and thus inserts can be performed almost at the speed of disk I/O.
2121

2222
## Storage Layer: Concurrent inserts and selects are isolated
2323

24-
On the other hand, merging parts is a background operation which is invisible to the user, i.e. does not affect concurrent SELECT queries. In fact, this architecture isolates insert and selects so effectively, that many other databases adopted it.
24+
Inserts are fully isolated from SELECT queries, and merging inserted data parts happens in the background without affecting concurrent queries.
2525

2626
## Storage Layer: Merge-time computation
2727

28-
Unlike other databases, ClickHouse is also able to perform additional data transformations during the merge operation. Examples of this include:
28+
Unlike other databases, ClickHouse keeps data writes lightweight and efficient by performing all additional data transformations during the [merge](/docs/en/merges) background process. Examples of this include:
2929

3030
- **Replacing merges** which retain only the most recent version of a row in the input parts and discard all other row versions. Replacing merges can be thought of as a merge-time cleanup operation.
3131

492 KB
Loading
3.4 MB
Loading
2.51 MB
Loading
2.89 MB
Loading
2.9 MB
Loading
2.89 MB
Loading
2.89 MB
Loading
2.81 MB
Loading

docs/en/managing-data/core-concepts/index.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,4 +12,5 @@ you will learn some of the core concepts of how ClickHouse works.
1212
|-------------------------------------------------------------|-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
1313
| [Table parts](/docs/en/parts) | Learn what table parts are in ClickHouse. |
1414
| [Table partitions](/docs/en/partitions) | Learn what table partitions are and what they are used for. |
15+
| [Table part merges](/docs/en/merges) | Learn what table part merges are and what they are used for. |
1516
| [Primary indexes](/docs/en/optimize/sparse-primary-indexes) | A deep dive into ClickHouse indexing including how it differs from other DB systems, how ClickHouse builds and uses a table's spare primary index and what some of the best practices are for indexing in ClickHouse. |

0 commit comments

Comments
 (0)