v.24.2New Feature

Implemented Automatic Conversion of Merge Tree Tables to Replicated Engine

Implemented automatic conversion of merge tree tables of different kinds to replicated engine. Create empty convert_to_replicated file in table's data directory (/clickhouse/store/xxx/xxxyyyyy-yyyy-yyyy-yyyy-yyyyyyyyyyyy/) and that table will be converted automatically on next server start. #57798 (Kirill).
Implemented automatic conversion of MergeTree tables to their replicated engine counterparts by creating a specific trigger file.

Why it matters

This feature solves the challenge of migrating existing MergeTree tables to replicated versions without manual complex operations. It simplifies the upgrade process by automating the conversion when triggered, ensuring data replication and improved fault tolerance.

How to use it

To enable the automatic conversion, create an empty file named convert_to_replicated inside the table's data directory (e.g., /clickhouse/store/xxx/xxxyyyyy-yyyy-yyyy-yyyy-yyyyyyyyyyyy/). Then, restart the ClickHouse server. On startup, the table will be automatically converted to its replicated engine equivalent.