Slide 28
Slide 28 text
@Incoming("orders")
@Outgoing("queue")
public CompletionStage prepare(String message) {
Order order = fromJson(message, Order.class);
return makeIt(order)
.thenApply(beverage ->
PreparationState.ready(order, beverage)
);
}
Process data async*
* Many other options available to produce, process or consume data
Read from “orders”
Write to “queue”
PROCESSING MESSAGES