25.02.2015 Views

Introducing Spring Framework

Introducing Spring Framework

Introducing Spring Framework

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Installing RabbitMQ on Windows<br />

Appendix A ■ Installing Tools<br />

RabbitMQ is based on the Erlang VM, so you need to install Erlang first. To install Erlang, go to www.erlang.org/download.html.<br />

Install version otp_win64_17.0.exe (remember to check your Windows OS version, either 32-bit or 64-bit). During<br />

the installation, choose the default settings. Also, you need to add the ERLANG_HOME environment variable and set it to<br />

C:\Program Files\erl6.0.<br />

To install RabbitMQ, go to www.rabbitmq.com/install-windows.html and download the rabbitmq-server-<br />

3.3.1.exe file. Double-click the file and choose the default settings. By default, the installer will set the RabbitMQ as a<br />

service, and it will start after you install it.<br />

You can start and stop RabbitMQ by going to Control Panel ➤ System and Security ➤ Administrative<br />

Tools ➤ Services and looking for RabbitMQ.<br />

Installing the RabbitMQ Web Console<br />

By default, RabbitMQ doesn’t have the web console enable, so you need to enable it by executing the following<br />

commands:<br />

C:\> cd “C:\Program Files (x86)\RabbitMQ Server\rabbitmq_server-3.3.1\sbin”<br />

C:\Program Files (x86)\RabbitMQ Server\rabbitmq_server-3.3.1\sbin> rabbitmq-plugins.bat enable<br />

rabbitmq_management<br />

After you execute the above commands, you need to restart RabbitMQ, and then you can go to<br />

http://localhost:15672/. The username and password are guest/guest.<br />

Installing RabbitMQ on a Mac OS X<br />

Remember to install Homebrew before you install RabbitMQ; if you haven’t installed it yet, you can take a look at the<br />

“Installing Homebrew” section of this appendix. To install RabbitMQ, execute the following commands:<br />

$ brew update<br />

$ brew install rabbitmq<br />

The above commands will install RabbitMQ and its dependency, the Erlang VM.<br />

RabbitMQ Useful Commands<br />

RabbitMQ has different commands that can be executed in the command line to start, stop, or check out the status<br />

of RabbitMQ.<br />

Start RabbitMQ<br />

To start RabbitMQ, execute the following command:<br />

$ brew services start rabbitmq<br />

==> Successfully started `rabbitmq` (label: homebrew.mxcl.rabbitmq)<br />

315

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!