Implementing Spring Boot messaging

In an ideal case, all microservice interactions are expected to happen asynchronously using publish-subscribe semantics. Spring Boot provides a hassle-free mechanism to configure messaging solutions:

Implementing Spring Boot messaging

In this example, we will create a Spring Boot application with a sender and receiver, both connected though an external queue. Perform the following steps:

Note

The full source code of this example is available as the chapter2.bootmessaging project in the code files of this book.

  1. Create a new project using STS to demonstrate this capability. In this example, instead of selecting Web, select AMQP under I/O:
  2. Rabbit MQ will ...

Get Spring Microservices now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.