.. | ||
go.mod | ||
go.sum | ||
offset_tracking_receive.go | ||
offset_tracking_send.go | ||
README.md | ||
receive.go | ||
send.go |
Go code for RabbitMQ tutorials
Here you can find Go code examples from RabbitMQ tutorials.
To successfully use the examples you will need a running RabbitMQ server with the stream plugin enabled.
See First Application With RabbitMQ Streams, Stream plugin documentation and how to preconfigure plugins.
Requirements
These examples use the rabbitmq/rabbitmq-stream-go-client
client library.
Get it first with
go get -u github.com/rabbitmq/rabbitmq-stream-go-client
Code
Code examples are executed via go run
:
go run send.go
go run receive.go
Tutorial two: Offset Tracking:
go run offset_tracking_send.go
go run offset_tracking_receive.go
To learn more, see rabbitmq/rabbitmq-stream-go-client
.