diff options
| author | Matthias Radestock <matthias@lshift.net> | 2010-02-04 19:12:17 +0000 |
|---|---|---|
| committer | Matthias Radestock <matthias@lshift.net> | 2010-02-04 19:12:17 +0000 |
| commit | 1f5a2d6b1e1e3628d3e60860b116b4f174c0fe72 (patch) | |
| tree | fe652367b44df90baa544ed4bc307840b7dba832 /src | |
| parent | 52dbedbbe9118627e05ccdac7475d5a14ccbd665 (diff) | |
| download | rabbitmq-server-git-1f5a2d6b1e1e3628d3e60860b116b4f174c0fe72.tar.gz | |
ditch API for channel-based consumer listing
Diffstat (limited to 'src')
| -rw-r--r-- | src/rabbit_channel.erl | 19 |
1 files changed, 1 insertions, 18 deletions
diff --git a/src/rabbit_channel.erl b/src/rabbit_channel.erl index 0dbcf1158e..d0b0ee9132 100644 --- a/src/rabbit_channel.erl +++ b/src/rabbit_channel.erl @@ -37,8 +37,7 @@ -export([start_link/5, do/2, do/3, shutdown/1]). -export([send_command/2, deliver/4, conserve_memory/2]). --export([list/0, info_keys/0, info/1, info/2, info_all/0, info_all/1, - consumers/1, consumers_all/0]). +-export([list/0, info_keys/0, info/1, info/2, info_all/0, info_all/1]). -export([init/1, terminate/2, code_change/3, handle_call/3, handle_cast/2, handle_info/2, handle_pre_hibernate/1]). @@ -83,8 +82,6 @@ -spec(info/2 :: (pid(), [info_key()]) -> [info()]). -spec(info_all/0 :: () -> [[info()]]). -spec(info_all/1 :: ([info_key()]) -> [[info()]]). --spec(consumers/1 :: (pid()) -> [{binary(), queue_name()}]). --spec(consumers_all/0 :: () -> [{pid(), binary(), queue_name()}]). -endif. @@ -134,16 +131,6 @@ info_all() -> info_all(Items) -> rabbit_misc:filter_exit_map(fun (C) -> info(C, Items) end, list()). -consumers(Pid) -> - gen_server2:pcall(Pid, 9, consumers, infinity). - -consumers_all() -> - lists:concat( - rabbit_misc:filter_exit_map( - fun (C) -> - [{C, Tag, QueueName} || {Tag, QueueName} <- consumers(C)] - end, list())). - %%--------------------------------------------------------------------------- init([Channel, ReaderPid, WriterPid, Username, VHost]) -> @@ -177,10 +164,6 @@ handle_call({info, Items}, _From, State) -> catch Error -> reply({error, Error}, State) end; -handle_call(consumers, _From, - State = #ch{consumer_mapping = ConsumerMapping}) -> - reply(dict:to_list(ConsumerMapping), State); - handle_call(_Request, _From, State) -> noreply(State). |
