summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorMatthew Sackman <matthew@rabbitmq.com>2011-02-12 20:59:39 +0000
committerMatthew Sackman <matthew@rabbitmq.com>2011-02-12 20:59:39 +0000
commit3a4196aefac0f4183eb98503bfbd360c6e0a2ceb (patch)
tree4db5dd22a572de81aaccd7a187fe96f6e1a4d99e /src
parent1678bb99d157e94cf8c904a8ab39e1a5f3898be0 (diff)
downloadrabbitmq-server-git-3a4196aefac0f4183eb98503bfbd360c6e0a2ceb.tar.gz
Added documentation for gm 'become' callback result
Diffstat (limited to 'src')
-rw-r--r--src/gm.erl14
1 files changed, 14 insertions, 0 deletions
diff --git a/src/gm.erl b/src/gm.erl
index 8fea919667..283b243171 100644
--- a/src/gm.erl
+++ b/src/gm.erl
@@ -432,6 +432,20 @@
behaviour_info(callbacks) ->
[
+ %% The joined, members_changed and handle_msg callbacks can all
+ %% return any of the following terms:
+ %%
+ %% 'ok' - the callback function returns normally
+ %%
+ %% {'stop', Reason} - the callback indicates the member should
+ %% stop with reason Reason and should leave the group.
+ %%
+ %% {'become', Module, Args} - the callback indicates that the
+ %% callback module should be changed to Module and that the
+ %% callback functions should now be passed the arguments
+ %% Args. This allows the callback module to be dynamically
+ %% changed.
+
%% Called when we've successfully joined the group. Supplied with
%% Args provided in start_link, plus current group members.
{joined, 2},