presentation-demo
presentation-demo
Install Crystal
In order to run these applications, you need to install the programming language Crystal. Please follow the instructions on the official website
For Linux
For Macos
For Windows
Clone this repository
git clone git@github.com:cloudamqp/presentation-demo.git
cd presentation-demo
Install the required dependencies for your app
shards update
shards install
Install LavinMQ
From source
Clone the git repository and build the project.
git clone git@github.com:cloudamqp/lavinmq.git
cd lavinmq
make
sudo make install # optional
Now, LavinMQ is ready to be used. You can check the version with:
lavinmq -v
Run LavinMQ with: lavinmq -D /var/lib/lavinmq
For MacOS
brew install lavinmq
brew services list
brew services start lavinmq
To stop Lavinmq: brew services stop lavinmq
For Linux(Ubuntu/Debian)
curl -fsSL https://packagecloud.io/cloudamqp/lavinmq/gpgkey | gpg --dearmor | sudo tee /usr/share/keyrings/lavinmq.gpg > /dev/null
. /etc/os-release
echo "deb [signed-by=/usr/share/keyrings/lavinmq.gpg] https://packagecloud.io/cloudamqp/lavinmq/$ID $VERSION_CODENAME main" | sudo tee /etc/apt/sources.list.d/lavinmq.list
sudo apt-get update
sudo apt-get install lavinmq
Run LavinMQ with: lavinmq -D /var/lib/lavinmq
Start LavinMQ
Run LavinMQ with: lavinmq -D /var/lib/lavinmq
Start app
Start the consumer in one terminal window: crystal run hello_world_consumer.cr
Start the publisher in another terminal window: crystal run hello_world_publisher.cr
Open LavinMQ management UI
Local LavinMQ
URL: http://localhost:15672/
Username: guest
Password: guest
LavinMQ running on CloudAMQP
URL: https://test-freezing-barnacle.lmq.cloudamqp.com/
Username: tjejerkodar
Password: 84codes
Nice to have
AMQP client libraries
Client for Crystal used in code along: https://github.com/cloudamqp/amqp-client.cr
More code examples: https://www.cloudamqp.com/docs/crystal.html
Clients for other languages and code examples: https://www.cloudamqp.com/docs/ruby.html#:~:text=HTTP-,CODE%20SAMPLE,-Ruby
presentation-demo
- 2
- 1
- 0
- 0
- 2
- 2 months ago
- September 7, 2023
Sat, 21 Dec 2024 23:03:15 GMT