From: Kai Moritz Date: Fri, 13 Oct 2023 12:16:23 +0000 (+0200) Subject: Beispiel: Schema erzeugen und abfragen X-Git-Tag: config/sasl-plain---2023-10-signal~8 X-Git-Url: http://juplo.de/gitweb/?a=commitdiff_plain;h=9ae28ada7d2a7b63ec9d6713fe5065efe8427e4a;p=demos%2Fkafka%2Ftraining Beispiel: Schema erzeugen und abfragen --- diff --git a/README.sh b/README.sh index 9eb16c4..4dd2854 100755 --- a/README.sh +++ b/README.sh @@ -32,3 +32,6 @@ echo docker-compose -f docker/docker-compose.yml exec cli kafkacat -C -b kafka:9092 -t test -o beginning -e kafkacat -L -b :9092 -Xsecurity.protocol=sasl_plaintext -Xsasl.mechanisms=PLAIN -Xsasl.username=client -Xsasl.password=client-secret + +cat user-v1.schema|http POST http://localhost:8085/subjects/user/versions "Content-Type:application/vnd.schemaregistry.v1+json" +http GET http://0:8085/subjects/user/versions/1/schema diff --git a/user-v1.schema b/user-v1.schema new file mode 100644 index 0000000..fb11282 --- /dev/null +++ b/user-v1.schema @@ -0,0 +1 @@ +{ "schema": "{ \"type\": \"record\", \"name\": \"de.trion.avro.User\", \"fields\": [ { \"name\": \"username\", \"type\": \"string\" } ] }" }