updating scs-099 tutorial

This commit is contained in:
Jay Ehsaniara
2021-05-18 09:26:53 -07:00
parent 5d29c0d0b1
commit 6604387604
7 changed files with 10 additions and 13 deletions

View File

@@ -2,7 +2,9 @@
## Producer Consumer
A simple Example of an Event Driven Flow by the help of **SPRING CLOUD STREAM KAFKA**
A simple example for an Event Driven Flow by the help of **SPRING CLOUD STREAM KAFKA**
![General Flow Diagram](material/kafka-events-intro-099-1.svg)
##### properties
@@ -12,8 +14,6 @@ A simple Example of an Event Driven Flow by the help of **SPRING CLOUD STREAM KA
The Docker-compose file contains: single kafka and zookeeper. just simply run the following command
![General Flow Diagram](material/kafka-events-intro-099-1.svg)
```shell
docker-compose up -d
```

File diff suppressed because one or more lines are too long

Before

Width:  |  Height:  |  Size: 119 KiB

After

Width:  |  Height:  |  Size: 119 KiB

File diff suppressed because one or more lines are too long

Before

Width:  |  Height:  |  Size: 27 KiB

After

Width:  |  Height:  |  Size: 27 KiB

File diff suppressed because one or more lines are too long

Before

Width:  |  Height:  |  Size: 33 KiB

After

Width:  |  Height:  |  Size: 33 KiB

File diff suppressed because one or more lines are too long

Before

Width:  |  Height:  |  Size: 33 KiB

After

Width:  |  Height:  |  Size: 33 KiB

View File

@@ -41,10 +41,7 @@ public class PobSubService {
String message = String.format("TestString of %s - %s", counter, value);
//here is out message publisher in the given channel into topic "scs-099.order"
myBinder.orderOut()
.send(MessageBuilder.withPayload(message)
.setHeader(MessageHeaders.CONTENT_TYPE, MimeTypeUtils.APPLICATION_JSON)
.build());
myBinder.orderOut().send(MessageBuilder.withPayload(message).build());
//to show what we have produced in kafka ("WARN" to show in different color on the console)
log.warn("message produced: {}", message);

View File

@@ -17,7 +17,7 @@ spring:
cloud.stream.bindings:
order-out.producer.partition-count: 10
order-in:
group: ${spring.application.name}-shipping-group
group: ${spring.application.name}-group
consumer.concurrency: 1
cloud.stream.kafka.binder:
@@ -31,7 +31,7 @@ spring:
cloud.stream.bindings:
order-out.producer.partition-count: 10
order-in:
group: ${spring.application.name}-shipping-group
group: ${spring.application.name}-group
consumer.concurrency: 3
cloud.stream.kafka.binder: