Hi guys
When trying the example schema in
http://confluent.io/docs/current/schema-registry/docs/api.html
POST /subjects/test HTTP/1.1Host: schemaregistry.example.comAccept:
application/vnd.schemaregistry.v1+json,
application/vnd.schemaregistry+json, application/json
{
"schema":
"{ \"type\": \"record\",
\"name\": \"test\", \"fields\": [
{ \"type\": \"string\",
\"name\": \"field1\" },
{ \"type\": \"integer\",
\"name\": \"field2\" } ]
}"
}
I get the following error...
IR-52:confluent-1.0 clint$ curl -X POST -i -H "Content-Type:
application/vnd.schemaregistry.v1+json" \
> --data '{"schema": "{ \"type\": \"record\", \"name\": \"test\", \"fields\":
> [{ \"type\": \"string\", \"name\": \"field1\" }, { \"type\": \"integer\",
> \"name\": \"field2\" }]}"}' \
> http://localhost:8081/subjects/Clint1-key/versions
HTTP/1.1 422
Content-Length: 71
Content-Type: application/vnd.schemaregistry.v1+json
Server: Jetty(8.1.16.v20140903)
{"error_code":42201,"message":"Input schema is an invalid Avro
schema"}IR-52:confluent-1.0 clint$
Please advise
Thanks