summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGerhard Lazu <gerhard@lazu.co.uk>2017-09-20 11:23:06 +0100
committerGerhard Lazu <gerhard@lazu.co.uk>2017-09-20 17:29:24 +0100
commit2f34158103d4e71c421fbd25952a5b066104a6c6 (patch)
tree54ad2d7b3dfc6ec69f4d081b7cfa2079aaec663c
parent07b85f64adab8d6f0ca979973435adb0470b5d03 (diff)
downloadrabbitmq-server-git-2f34158103d4e71c421fbd25952a5b066104a6c6.tar.gz
Explain the IoBatchSize role in push_betas_to_deltas
-rw-r--r--src/rabbit_variable_queue.erl3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/rabbit_variable_queue.erl b/src/rabbit_variable_queue.erl
index e408029877..d50490544c 100644
--- a/src/rabbit_variable_queue.erl
+++ b/src/rabbit_variable_queue.erl
@@ -2384,6 +2384,9 @@ reduce_memory_use(State = #vqstate {
end,
State3 =
+ %% If there are more messages with their queue position held in RAM,
+ %% a.k.a. betas, in Q2 & Q3 than IoBatchSize,
+ %% write their queue position to disk, a.k.a. push_betas_to_deltas
case chunk_size(?QUEUE:len(Q2) + ?QUEUE:len(Q3),
permitted_beta_count(State1)) of
S2 when S2 >= IoBatchSize ->