From a8baff61ec9a035f8e5a58d171942bd3c8f7e9c6 Mon Sep 17 00:00:00 2001 From: Andrew Mayorov Date: Wed, 20 Mar 2024 12:28:58 +0100 Subject: [PATCH] docs(dsrepl): describe briefly what `n_sites` is for --- apps/emqx/src/emqx_ds_schema.erl | 6 ++++-- rel/i18n/emqx_ds_schema.hocon | 9 +++++++++ 2 files changed, 13 insertions(+), 2 deletions(-) diff --git a/apps/emqx/src/emqx_ds_schema.erl b/apps/emqx/src/emqx_ds_schema.erl index 4b9eb8773..bbbd4eafd 100644 --- a/apps/emqx/src/emqx_ds_schema.erl +++ b/apps/emqx/src/emqx_ds_schema.erl @@ -131,12 +131,14 @@ fields(builtin) -> desc => ?DESC(builtin_n_shards) } )}, - %% TODO: Minimum number of sites that will be responsible for the shards + %% TODO: Deprecate once cluster management and rebalancing is implemented. {"n_sites", sc( pos_integer(), #{ - default => 1 + default => 1, + importance => ?IMPORTANCE_HIDDEN, + desc => ?DESC(builtin_n_sites) } )}, {replication_factor, diff --git a/rel/i18n/emqx_ds_schema.hocon b/rel/i18n/emqx_ds_schema.hocon index 89a276275..11d25ebe4 100644 --- a/rel/i18n/emqx_ds_schema.hocon +++ b/rel/i18n/emqx_ds_schema.hocon @@ -30,6 +30,15 @@ builtin_n_shards.desc: Please note that it takes effect only during the initialization of the durable storage database. Changing this configuration parameter after the database has been already created won't take any effect.~""" +builtin_n_sites.label: "Initial number of sites" +builtin_n_sites.desc: + """~ + Number of storage sites that need to share responsibility over the set of storage shards. + In this context, sites are essentially EMQX nodes that have message durability enabled. + Please note that it takes effect only during the initialization of the durable storage database. + During this phase at least that many sites should come online to distribute shards between them, otherwise message storage will be unavailable until then. + After the initialization is complete, sites may be offline, which will affect availability depending on the number of offline sites and replication factor.~""" + builtin_local_write_buffer.label: "Local write buffer" builtin_local_write_buffer.desc: """~