diff options
| author | Matthias Radestock <matthias@lshift.net> | 2008-12-18 21:05:20 +0000 |
|---|---|---|
| committer | Matthias Radestock <matthias@lshift.net> | 2008-12-18 21:05:20 +0000 |
| commit | fe254441a23a743d8acce78a64356249fdcd4db5 (patch) | |
| tree | 6b004a928efd3bbd3cba4f9e54af3882f2e126ee /src | |
| parent | bedbed08168937defde1c1d6e8407c71cf4ab9a2 (diff) | |
| download | rabbitmq-server-git-fe254441a23a743d8acce78a64356249fdcd4db5.tar.gz | |
tidy comments
Diffstat (limited to 'src')
| -rw-r--r-- | src/rabbit_limiter.erl | 21 |
1 files changed, 10 insertions, 11 deletions
diff --git a/src/rabbit_limiter.erl b/src/rabbit_limiter.erl index e5e54563f4..e225e82734 100644 --- a/src/rabbit_limiter.erl +++ b/src/rabbit_limiter.erl @@ -55,11 +55,10 @@ queues = dict:new(), in_use = 0}). -%--------------------------------------------------------------------------- -% API -%--------------------------------------------------------------------------- +%%---------------------------------------------------------------------------- +%% API +%-%--------------------------------------------------------------------------- -% Kicks this pig start_link(ChPid) -> {ok, Pid} = gen_server:start_link(?MODULE, [ChPid], []), Pid. @@ -67,19 +66,19 @@ start_link(ChPid) -> set_prefetch_count(LimiterPid, PrefetchCount) -> gen_server:cast(LimiterPid, {prefetch_count, PrefetchCount}). -% Queries the limiter to ask whether the queue can deliver a message -% without breaching a limit +%% Ask the limiter whether the queue can deliver a message without +%% breaching a limit can_send(LimiterPid, QPid) -> gen_server:call(LimiterPid, {can_send, QPid}). -% Lets the limiter know that a queue has received an ack from a consumer -% and hence can reduce the in-use-by-that queue capcity information +%% Let the limiter know that the channel has received some acks from a +%% consumer decrement_capacity(LimiterPid, Magnitude) -> gen_server:cast(LimiterPid, {decrement_capacity, Magnitude}). -%--------------------------------------------------------------------------- -% gen_server callbacks -%--------------------------------------------------------------------------- +%%---------------------------------------------------------------------------- +%% gen_server callbacks +%%---------------------------------------------------------------------------- init([ChPid]) -> {ok, #lim{ch_pid = ChPid} }. |
