summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon MacMullen <simon@rabbitmq.com>2014-02-05 14:36:29 +0000
committerSimon MacMullen <simon@rabbitmq.com>2014-02-05 14:36:29 +0000
commit1fbd4b7d3971f08148c70b00054da60437f1e920 (patch)
tree67ddea00ef8d8d4d8464dd8705750187e32d2b55
parentadaa7d05a6da234013e09854944e8d93a9fc75eb (diff)
downloadrabbitmq-server-1fbd4b7d3971f08148c70b00054da60437f1e920.tar.gz
I don't think we do need to notify. Also, add specs.
-rw-r--r--src/rabbit_runtime_parameters.erl9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/rabbit_runtime_parameters.erl b/src/rabbit_runtime_parameters.erl
index 69f2f524..35b3aace 100644
--- a/src/rabbit_runtime_parameters.erl
+++ b/src/rabbit_runtime_parameters.erl
@@ -36,6 +36,7 @@
-> ok_or_error_string()).
-spec(set_any/4 :: (rabbit_types:vhost(), binary(), binary(), term())
-> ok_or_error_string()).
+-spec(set_global/2 :: (atom(), term()) -> 'ok').
-spec(clear/3 :: (rabbit_types:vhost(), binary(), binary())
-> ok_or_error_string()).
-spec(clear_any/3 :: (rabbit_types:vhost(), binary(), binary())
@@ -50,6 +51,8 @@
-> rabbit_types:infos() | 'not_found').
-spec(value/3 :: (rabbit_types:vhost(), binary(), binary()) -> term()).
-spec(value/4 :: (rabbit_types:vhost(), binary(), binary(), term()) -> term()).
+-spec(value_global/1 :: (atom()) -> term() | 'not_found').
+-spec(value_global/2 :: (atom(), term()) -> term()).
-spec(info_keys/0 :: () -> rabbit_types:info_keys()).
-endif.
@@ -77,10 +80,8 @@ set(VHost, Component, Name, Term) ->
set_any(VHost, Component, Name, Term).
set_global(Name, Term) ->
- case mnesia_update(Name, Term) of
- {old, Term} -> ok;
- _ -> ok %% TODO notify
- end.
+ mnesia_update(Name, Term),
+ ok.
format_error(L) ->
{error_string, rabbit_misc:format_many([{"Validation failed~n", []} | L])}.