File tree Expand file tree Collapse file tree 2 files changed +10
-3
lines changed Expand file tree Collapse file tree 2 files changed +10
-3
lines changed Original file line number Diff line number Diff line change @@ -14,7 +14,12 @@ Code examples are executed via `elixir`:
1414
1515Tutorial one: "Hello World!":
1616
17- elixir publish.exs
18- elixir consume.exs
17+ ``` shell
18+ # run the publisher
19+ elixir publish.exs
20+
21+ # run the consumer
22+ elixir consume.exs
23+ ```
1924
2025To learn more, see [ ` VictorGaiva/rabbitmq-stream ` ] ( https://github.com/VictorGaiva/rabbitmq-stream ) .
Original file line number Diff line number Diff line change @@ -9,7 +9,9 @@ Mix.install([
99# First we start a Connection to the RabbitMQ Server
1010{ :ok , connection } = RabbitMQStream.Connection . start_link ( )
1111
12- # We can assume the stream already exists as this sample is meant to be run after the 'publish.exs' sample
12+ # We can assume the stream doesn't exist yet, and attempt to create it. If it already exists,
13+ # it should be still be good to go.
14+ RabbitMQStream.Connection . create_stream ( connection , "my_stream" )
1315
1416# Now we can subscribe to the stream, receiving up to 1 chunk.
1517{ :ok , subscription_id } =
You can’t perform that action at this time.
0 commit comments