Here, I am using the same application as both producer and consumer for the convenience of the demo.
fizzBuzzProducer is the producer which will generate the random number within range for every 5 seconds.
fizzBuzzProcessor is the processor just like middleware, the number generated by the producer. This acts as a consumer from the previously produced message and processes the logic of fizzBuzz logic and published to another topic.
fizzBuzzConsumer will consume the message that is published by the processor and prints out in the console.
The use case seems simple, my intention is to show who Java Functional Programming can be used to define producers, consumers in Spring boot application of course multiple topics.