Waiting for Dalston.M1 because of this issue: https://github.com/spring-cloud/spring-cloud-stream/issues/686
import org.springframework.boot.CommandLineRunner;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
+import org.springframework.cloud.stream.schema.client.EnableSchemaRegistryClient;
import org.springframework.context.annotation.Bean;
@SpringBootApplication
+@EnableSchemaRegistryClient
public class Application {
public static void main(String[] args) {
output:
binder: kafka
destination: test
+ # Using Apache Avro with Schema Registry
+ # contentType: application/*+avro
contentType: application/json
# Consumer (input) and producer (output) are Spring Cloud Stream applications :)
headerMode: embeddedHeaders
zkNodes: "kafka:2181"
brokers: "kafka:9092,kafka:9093,kafka:9094"
autoCreateTopics: true
+ schemaRegistryClient: "http://localhost:8888/schema-registry/"
# Health indicator for binders.
management:
package de.example.spring.kafka;
-import org.springframework.boot.CommandLineRunner;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
-import org.springframework.context.annotation.Bean;
import org.springframework.cloud.stream.schema.server.EnableSchemaRegistryServer;
@SpringBootApplication
stream:
schema:
server:
- path: schema
+ path: schema-registry