Files
spring-cloud-stream/spring-cloud-stream-samples/sink
Thomas Risberg 65240966e3 Update README.md
2015-07-30 15:27:34 -04:00
..
2015-07-21 15:34:29 -04:00
2015-07-30 15:27:34 -04:00

Spring Cloud Stream Sink Sample

In this Spring Cloud Stream sample, messages are received from a stream and the payload of each is logged to the console.

Requirements

To run this sample, you will need to have installed:

  • Java 8 or Above

This example requires Redis to be running on localhost.

Code Tour

This sample is a Spring Boot application that uses Spring Cloud Stream to receive messages and write each payload to the console. The sink module has 2 primary components:

  • SinkApplication - the Spring Boot Main Application
  • LogSink - the module that receives the data from the stream and writes it out to the console

Building with Maven

Build the sample by executing:

sink>$ mvn clean package

Running the Sample

To start the sink module execute the following:

sink>$ java -jar target/spring-cloud-stream-sample-sink-1.0.0.BUILD-SNAPSHOT-exec.jar