rabbitmq-tutorials/julia
2021-10-04 00:21:02 +05:30
..
emit_log_direct.jl Add julia RabbitMQ examples 2021-10-04 00:21:02 +05:30
emit_log_topic.jl Add julia RabbitMQ examples 2021-10-04 00:21:02 +05:30
emit_log.jl Add julia RabbitMQ examples 2021-10-04 00:21:02 +05:30
new_task.jl Add julia RabbitMQ examples 2021-10-04 00:21:02 +05:30
README.md Add julia RabbitMQ examples 2021-10-04 00:21:02 +05:30
receive_logs_direct.jl Add julia RabbitMQ examples 2021-10-04 00:21:02 +05:30
receive_logs_topic.jl Add julia RabbitMQ examples 2021-10-04 00:21:02 +05:30
receive_logs.jl Add julia RabbitMQ examples 2021-10-04 00:21:02 +05:30
receive.jl Add julia RabbitMQ examples 2021-10-04 00:21:02 +05:30
rpc_client.jl Add julia RabbitMQ examples 2021-10-04 00:21:02 +05:30
rpc_server.jl Add julia RabbitMQ examples 2021-10-04 00:21:02 +05:30
send.jl Add julia RabbitMQ examples 2021-10-04 00:21:02 +05:30
worker.jl Add julia RabbitMQ examples 2021-10-04 00:21:02 +05:30

Julia code for RabbitMQ tutorials

Here you can find Julia code examples from RabbitMQ tutorials.

To successfully use the examples you will need a running RabbitMQ server.

Requirements

To run this code you need to install the AMQPClient and JSON. To install it, run

julia> using Pkg

julia> Pkg.add("AMQPClient")
    Updating registry at `~/.julia/registries/General`
   Resolving package versions...
  No Changes to `~/.julia/environments/v1.6/Project.toml`
  No Changes to `~/.julia/environments/v1.6/Manifest.toml`

julia> Pkg.add("JSON")
   Resolving package versions...
  No Changes to `~/.julia/environments/v1.6/Project.toml`
  No Changes to `~/.julia/environments/v1.6/Manifest.toml`

Code

Tutorial one: "Hello World!"

julia send.jl
julia receive.jl

Tutorial two: Work Queues:

julia new_task.jl "A very hard task which takes two seconds.."
julia worker.jl

Tutorial three: Publish/Subscribe

julia receive_logs.jl
julia emit_log.jl "info: This is the log message"

Tutorial four: Routing

julia receive_logs_direct.jl info
julia emit_log_direct.jl info "The message"

Tutorial five: Topics

julia receive_logs_topic.jl "*.rabbit"
julia emit_log_topic.jl red.rabbit Hello

Tutorial six: RPC

julia rpc_server.jl
julia rpc_client.jl