diff options
author | Tim Watson <watson.timothy@gmail.com> | 2014-01-14 14:15:13 +0000 |
---|---|---|
committer | Tim Watson <watson.timothy@gmail.com> | 2014-01-14 14:15:13 +0000 |
commit | 3ed0daee5ed2452242ef99777e24a447999605bf (patch) | |
tree | 49bb520672144e94cb447e556cecdb2cc57aef14 /src/rabbit_backing_queue.erl | |
parent | 6bbdc4d5c5d1712ca2e58544ed753a69339577ce (diff) | |
download | rabbitmq-server-3ed0daee5ed2452242ef99777e24a447999605bf.tar.gz |
Refactor / maintain a clean interface to the backing queue
Instead of passing amqqueue records to BQ:start/1, revert to passing
queue names and return a list of queue recovery terms ordered
identically to the given queue names. As a result, we can go back to
keying recovery data off the unique queue directory (base)name and no
longer need to track the queue name in the qi. We now also only need
the queue directory name to lookup recovery terms.
Also update the BQ interface documentation and callbacks/specs.
Diffstat (limited to 'src/rabbit_backing_queue.erl')
-rw-r--r-- | src/rabbit_backing_queue.erl | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/rabbit_backing_queue.erl b/src/rabbit_backing_queue.erl index 9e1ebf41..11563a4e 100644 --- a/src/rabbit_backing_queue.erl +++ b/src/rabbit_backing_queue.erl @@ -41,7 +41,11 @@ %% aren't being started at this point, but this call allows the %% backing queue to perform any checking necessary for the consistency %% of those queues, or initialise any other shared resources. --callback start([rabbit_types:amqqueue()]) -> rabbit_types:ok(recovery_terms()). +%% +%% The list of queue recovery terms returned as {ok, Terms} MUST be given +%% in the same order as the list of queue names supplied. +%% +-callback start([rabbit_amqqueue:name()]) -> rabbit_types:ok(recovery_terms()). %% Called to tear down any state/resources. NB: Implementations should %% not depend on this function being called on shutdown and instead |