diff options
| author | Emile Joubert <emile@rabbitmq.com> | 2011-11-30 10:39:28 +0000 |
|---|---|---|
| committer | Emile Joubert <emile@rabbitmq.com> | 2011-11-30 10:39:28 +0000 |
| commit | 13803279ade65e65ab2f0de01ff26b1ef155b258 (patch) | |
| tree | 8093b0a134e503f7908429859896c19b7d0c4dc1 | |
| parent | 28938a35c5ada85c5553ec45f7d769b62aad4fa1 (diff) | |
| download | rabbitmq-server-git-13803279ade65e65ab2f0de01ff26b1ef155b258.tar.gz | |
Advice for windows service users when changing plugins
| -rw-r--r-- | docs/rabbitmq-service.xml | 3 | ||||
| -rw-r--r-- | src/rabbit_plugins.erl | 20 |
2 files changed, 18 insertions, 5 deletions
diff --git a/docs/rabbitmq-service.xml b/docs/rabbitmq-service.xml index 3368960b80..a4bd158087 100644 --- a/docs/rabbitmq-service.xml +++ b/docs/rabbitmq-service.xml @@ -66,7 +66,8 @@ Display usage information. <para> Install the service. The service will not be started. Subsequent invocations will update the service parameters if -relevant environment variables were modified. +relevant environment variables were modified or if the active +plugins were changed. </para> </listitem> </varlistentry> diff --git a/src/rabbit_plugins.erl b/src/rabbit_plugins.erl index 0862f1b2c7..62c004f74c 100644 --- a/src/rabbit_plugins.erl +++ b/src/rabbit_plugins.erl @@ -111,8 +111,7 @@ action(enable, ToEnable0, _Opts, PluginsFile, PluginsDir) -> [] -> io:format("Plugin configuration unchanged.~n"); _ -> print_list("The following plugins have been enabled:", NewImplicitlyEnabled -- ImplicitlyEnabled), - io:format("Plugin configuration has changed. " - "Restart RabbitMQ for changes to take effect.~n") + report_change() end; action(disable, ToDisable0, _Opts, PluginsFile, PluginsDir) -> @@ -140,8 +139,7 @@ action(disable, ToDisable0, _Opts, PluginsFile, PluginsDir) -> print_list("The following plugins have been disabled:", ImplicitlyEnabled -- NewImplicitlyEnabled), write_enabled_plugins(PluginsFile, NewEnabled), - io:format("Plugin configuration has changed. " - "Restart RabbitMQ for changes to take effect.~n") + report_change() end. %%---------------------------------------------------------------------------- @@ -374,3 +372,17 @@ maybe_warn_mochiweb(Enabled) -> false -> ok end. + +report_change() -> + io:format("Plugin configuration has changed. " + "Restart RabbitMQ for changes to take effect.~n"), + case os:type() of + {win32, _OsName} -> + io:format("If you have RabbitMQ running as a service then you must" + " reinstall by running~n rabbitmq-service.bat stop~n" + " rabbitmq-service.bat install~n" + " rabbitmq-service.bat start~n~n"); + _ -> + ok + end. + |
