confluentinc / schema-registry

Confluent Schema Registry for Kafka
https://docs.confluent.io/current/schema-registry/docs/index.html
Other
2.22k stars 1.11k forks source link

problem registering a new schema version #518

Closed margitbomholt closed 1 year ago

margitbomholt commented 7 years ago

We are using confluent platform 3.2 the following 2 "contents " were send by postman, using the http post : http://:8081/subjects/orders-value/versions

  1. version {"schema": "{\"type\":\"record\",\"name\":\"myrecord\",\"fields\":[{\"name\":\"id\",\"type\":\"int\"},{\"name\":\"product\",\"type\":\"string\"},{\"name\":\"quantity\",\"type\":\"int\"},{\"name\":\"price\",\"type\":\"float\"}]}"}

  2. version : {"schema": "{\"type\":\"record\",\"name\":\"myrecord\",\"fields\":[{\"name\":\"id\",\"type\":\"int\"},{\"name\":\"product\",\"type\":\"string\"},{\"name\":\"quantity\",\"type\":\"int\"},{\"name\":\"price\",\"type\":\"float\"},{\"name\":\"edu\",\"type\":\"string\",\"default\":\"testing\"}]}"}

the last post gave the error: { "error_code": 409, "message": "Schema being registered is incompatible with an earlier schema" } both "backward" and "full" compatibility has been tried. when using "none" its ok. I have read the issue/answer: https://groups.google.com/forum/#!topic/confluent-platform/Z9iOQcgA8aQ, but it doesn't seem to work for me, I must be doing something wrong ?? Any comments is highly appreceated

iMajna commented 7 years ago

+1

lojones commented 7 years ago

Did you find a solution to this? I had the same issue but once I defined the default value for my new field and rebuilt my avro pojos it fixed it.

margitbomholt commented 7 years ago

Hi

No, we did not. But thanks for your answer we will try do do so.

Med venlig hilsen

Margit Kjær Bomholt GIS udvikler

http://www.artogis.dk/

mkb@artogis.dk mailto:mkb@artogis.dk
Fra: lojones [mailto:notifications@github.com] Sendt: 2. oktober 2017 22:16 Til: confluentinc/schema-registry Cc: Margit Kjær Bomholt; Author Emne: Re: [confluentinc/schema-registry] problem registering a new schema version (#518)

Did you find a solution to this? I had the same issue but once I defined the default value for my new field and rebuilt my avro pojos it fixed it. — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/confluentinc/schema-registry/issues/518#issuecomment-333648173 , or mute the thread https://github.com/notifications/unsubscribe-auth/AFuJHBr09zVKJAUDs7cxLEtZ4unMwojnks5soUFSgaJpZM4MqWU- . https://github.com/notifications/beacon/AFuJHH0En0tZDZw2PEb7jAwPzmczeCKMks5soUFSgaJpZM4MqWU-.gif

kgneng2 commented 7 years ago

I had the same issue. I understand that full compatibility is not working..... , so use "none" compatibility.

jinze1107 commented 6 years ago

+1

jinze1107 commented 6 years ago

how to fix it?

ervitis commented 6 years ago

We are having the same problem in our project.

natezhengbne commented 6 years ago

try these https://stackoverflow.com/questions/49801055/kafka-schema-registry-not-compatible-in-the-same-topic

barambani commented 5 years ago

+1

gmyrianthous commented 5 years ago

Here's a workaround:

https://stackoverflow.com/a/49810035/7131757

rayokota commented 1 year ago

I believe this is no longer an issue, so closing. Please reopen if it is still an issue.