Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 4 additions & 0 deletions deps/rabbit/docs/rabbitmq.conf.example
Original file line number Diff line number Diff line change
Expand Up @@ -487,6 +487,10 @@
## when there are multiple publishers sending to the same quorum queue.
# quorum_queue.commands_soft_limit = 32

## Sets the maximum size of Raft log segment files for quorum queues.
##
# quorum_queue.segment_max_size_bytes = 64000000

## Changes classic queue storage implementation version.
## As of 4.0.0, version 2 is the default and this is a forward compatibility setting,
## that is, it will be useful when a new version is developed.
Expand Down
14 changes: 14 additions & 0 deletions deps/rabbit/priv/schema/rabbit.schema
Original file line number Diff line number Diff line change
Expand Up @@ -2754,6 +2754,20 @@ end}.
{validators, ["non_zero_positive_integer"]}
]}.

{mapping, "quorum_queue.segment_max_size_bytes", "rabbit.quorum_segment_max_size_bytes", [
{datatype, integer},
{validators, ["non_zero_positive_integer"]}
]}.
Comment thread
kjnilsson marked this conversation as resolved.

{translation, "rabbit.quorum_segment_max_size_bytes",
fun(Conf) ->
case cuttlefish:conf_get("quorum_queue.segment_max_size_bytes", Conf, undefined) of
undefined -> cuttlefish:unset();
Val -> Val
end
end
}.

Comment thread
kjnilsson marked this conversation as resolved.
Outdated
Comment thread
kjnilsson marked this conversation as resolved.
Outdated
%%
%% Quorum Queue membership reconciliation
%%
Expand Down
4 changes: 4 additions & 0 deletions deps/rabbit/src/rabbit_ra_systems.erl
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
-define(COORD_WAL_MAX_SIZE_B, 64_000_000).
-define(QUORUM_AER_MAX_RPC_SIZE, 16).
-define(QUORUM_DEFAULT_WAL_MAX_ENTRIES, 500_000).
-define(QUORUM_DEFAULT_SEGMENT_MAX_SIZE_B, 64_000_000).
%% the default min bin vheap value in OTP 26
-define(MIN_BIN_VHEAP_SIZE_DEFAULT, 46422).
-define(MIN_BIN_VHEAP_SIZE_MULT, 64).
Expand Down Expand Up @@ -133,6 +134,8 @@ get_config(quorum_queues = RaSystem) ->
_ ->
?MIN_BIN_VHEAP_SIZE_DEFAULT
end,
SegmentMaxSizeBytes = application:get_env(rabbit, quorum_segment_max_size_bytes,
?QUORUM_DEFAULT_SEGMENT_MAX_SIZE_B),
Comment thread
kjnilsson marked this conversation as resolved.
Outdated

DefaultConfig#{name => RaSystem,
wal_min_bin_vheap_size => MinBinVheapSize,
Expand All @@ -142,6 +145,7 @@ get_config(quorum_queues = RaSystem) ->
wal_max_entries => WalMaxEntries,
segment_compute_checksums => SegmentChecksums,
compress_mem_tables => CompressMemTables,
Comment thread
kjnilsson marked this conversation as resolved.
segment_max_size_bytes => SegmentMaxSizeBytes,
Comment thread
kjnilsson marked this conversation as resolved.
server_recovery_strategy => {rabbit_quorum_queue,
system_recover, []}};
get_config(coordination = RaSystem) ->
Expand Down
7 changes: 7 additions & 0 deletions deps/rabbit/test/config_schema_SUITE_data/rabbit.snippets
Original file line number Diff line number Diff line change
Expand Up @@ -1160,6 +1160,13 @@ credential_validator.regexp = ^abc\\d+",
]}],
[]},

{quorum_queue_segment_max_size_bytes,
"quorum_queue.segment_max_size_bytes = 64000000",
[{rabbit, [
{quorum_segment_max_size_bytes, 64000000}
]}],
[]},

%%
%% Runtime parameters
%%
Expand Down
Loading