Support Questions
Find answers, ask questions, and share your expertise

AvroSchema getting error after restarts schema-registry service.

AvroSchema getting error after restarts schema-registry service.

Explorer

Hello, 

I am using schema registry version 0.8.1 in Cloudera 7.1.3.
Facing issue when restarting schema registry service.
Initial state when creating an Avro schema and get information of the schema by
the following curl request:

POST /api/v1/confluent/subjects/{subject}


then its return success response, but after restart schema-registry service, its return 'Not Found (404)' response

like: 

{
  "responseCode": 1101,
  "responseMessage": "Entity with id [SCHEMA-value] not found."
}

 

For example, when I use the bellow type of schema, it getting an error after the restart. we investigate that it does not return the same fingerprint 

{
    "type": "record",
    "name": "record",
    "doc": "Schema generated by Kite",
    "fields": [
        {
            "name": "name",
            "type": [
                "null",
                "string"
            ],
            "default": null
        },
        {
            "name": "age",
            "type": [
                "null",
                "long"
            ],
            "default": null
        }
    ]
}

 

but for this schema

{
    "type": "record",
    "name": "record",
    "doc": "Schema generated by Kite",
    "fields": [
        {
            "name": "name",
            "type": [
                "string",
                "null"
            ]
        },
        {
            "name": "age",
            "type": [
                "long",
                "null"
            ]
        }
    ]
}

always returns the same fingerprint and working fine between restarts.
so my question is, what is a workaround if want to use the first version?