Loading
With curl commands, schemas can be retrieved/updated to Confluent SchemaRegistry.
curl -X GET http://localhost:8081/subjects/testtopic-value/versions/latest
curl -X GET http://localhost:8081/config/testtopic-value
curl -X GET http://localhost:8081/subjects/testtopic-value/versions
[1,2,3]
curl -X GET http://localhost:8081/subjects
curl -X POST -H "Content-Type: application/vnd.schemaregistry.v1+json" \
--data '{"schema": "{\"type\": \"string\"}"}' \
http://localhost:8081/compatibility/subjects/testtopic-value/versions/latest
curl -X PUT -H "Content-Type: application/vnd.schemaregistry.v1+json" --data '{"compatibility": "BACKWARD"}' http://localhost:8081/config/testtopic-value
curl -X PUT -H "Content-Type: application/vnd.schemaregistry.v1+json" --data '{"compatibility": "NONE"}' http://localhost:8081/config/testtopic-value
curl -X POST -H "Content-Type: application/vnd.schemaregistry.v1+json" --data '{"schema": "{\"type\": \"int\"}"}' http://localhost:8081/subjects/testtopic-value/versions
With a file :
curl -X POST -H "Content-Type: application/vnd.schemaregistry.v1+json" --data @test1.avsc http://localhost:8082/subjects/testtopic-value/versions
curl -X POST -H "Content-Type: application/vnd.schemaregistry.v1+json" \
--data '{"schema": "{ \"namespace\": \"emp3.avro\", \"type\": \"record\", \"name\": \"Emp1\", \"fields\": [ { \"type\": \"int\", \"name\": \"empid\" } , { \"type\": \"string\", \"name\": \"empname\" }, { \"type\": \"string\", \"name\": \"address\" } ] }" }' \
http://localhost:5081/subjects/testtopic-value/versions