이 콘텐츠는 선택한 언어로 제공되지 않습니다.
Appendix C. Using AMQ Broker with the examples
The AMQ Ruby examples require a running message broker with a queue named examples
. Use the procedures below to install and start the broker and define the queue.
C.1. Installing the broker 링크 복사링크가 클립보드에 복사되었습니다!
Follow the instructions in Getting Started with AMQ Broker to install the broker and create a broker instance. Enable anonymous access.
The following procedures refer to the location of the broker instance as <broker-instance-dir>
.
C.2. Starting the broker 링크 복사링크가 클립보드에 복사되었습니다!
Procedure
Use the
artemis run
command to start the broker.<broker-instance-dir>/bin/artemis run
$ <broker-instance-dir>/bin/artemis run
Copy to Clipboard Copied! Toggle word wrap Toggle overflow Check the console output for any critical errors logged during startup. The broker logs
Server is now live
when it is ready.Copy to Clipboard Copied! Toggle word wrap Toggle overflow
C.3. Creating a queue 링크 복사링크가 클립보드에 복사되었습니다!
In a new terminal, use the artemis queue
command to create a queue named examples
.
<broker-instance-dir>/bin/artemis queue create --name examples --address examples --auto-create-address --anycast
$ <broker-instance-dir>/bin/artemis queue create --name examples --address examples --auto-create-address --anycast
You are prompted to answer a series of yes or no questions. Answer N
for no to all of them.
Once the queue is created, the broker is ready for use with the example programs.
C.4. Stopping the broker 링크 복사링크가 클립보드에 복사되었습니다!
When you are done running the examples, use the artemis stop
command to stop the broker.
<broker-instance-dir>/bin/artemis stop
$ <broker-instance-dir>/bin/artemis stop
Revised on 2020-06-16 17:53:38 UTC