.. | ||
01-hello-world | ||
02-work-queues | ||
03-publish-subscribe | ||
04-routing | ||
.gitignore | ||
README.md |
Rust code for RabbitMQ tutorials
Here you can find the Rust code examples for RabbitMQ tutorials.
The examples use lapin client library.
To successfully use the examples you will need a running RabbitMQ server.
Requirements
Code
Each tutorial is a separate crate where each source file corresponds to a binary executable.
Tutorial one: "Hello World!"
cd 01-hello-world
Start receiver and sender in two separate shells:
cargo run --bin receive
cargo run --bin send
Tutorial two: Work Queues
cd 02-work-queues
Start workers and task creator in separate shells:
cargo run --bin worker
cargo run --bin new-task "hi" # specify a custom message
Tutorial three: Publish/Subscribe
cd 03-publish-subscribe
Start receiver and emitter in separate shells:
cargo run --bin receive
cargo run --bin emit "hi" # specify a custom message
Tutorial four: Routing
cd 04-routing
Start receiver and emitter in separate shells:
cargo run --bin receive info error # specify log levels
cargo run --bin emit-direct error "help!" # specify severity and custom message
Tutorial five: Topics
// TODO