v.20.4Improvement

Add ON CLUSTER Support for User/Role/Policy Commands and GRANT

Add ON CLUSTER clause support to commands {CREATE|DROP} USER/ROLE/ROW POLICY/SETTINGS PROFILE/QUOTA, GRANT. #9811 (Vitaly Baranov)
Added support for the ON CLUSTER clause in user, role, row policy, settings profile, quota management commands, and the GRANT statement.

Why it matters

This feature allows database administrators to execute security-related commands on all nodes of a cluster simultaneously, ensuring consistent user, role, policy, and permission management across distributed ClickHouse deployments.

How to use it

Append the ON CLUSTER <cluster_name> clause to the following commands: CREATE USER, DROP USER, CREATE ROLE, DROP ROLE, CREATE ROW POLICY, DROP ROW POLICY, CREATE SETTINGS PROFILE, DROP SETTINGS PROFILE, CREATE QUOTA, DROP QUOTA, and GRANT. This will apply the command across all nodes in the specified cluster.