Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Omit references if nil #68

Closed

Conversation

arnaldur
Copy link

@arnaldur arnaldur commented Feb 8, 2022

Rationale is that karapace fails if references is set, even if empty: "Unrecognized field: references"

In order to keep srclient compatible I suggest omitting References if nil.

Aiven-Open/karapace#195

note, not tested with other registries.

@riferrei
Copy link
Owner

riferrei commented Feb 8, 2022

I understand the rationale behind this PR, but I don't feel comfortable approving it as it targets a schema registry not intended to be supported by this library. I am not totally against providing support for other registries than Confluent's Schema Registry, as long extensible tests are made on it to make sure nothing will break. Furthermore, support for references is a thing in most registries these days, so maybe this fix should be worked out on Karaspace's side instead of on the client?

I propose closing this PR for now and moving this into an issue to be discussed.

@AtakanColak thoughts?

@arnaldur
Copy link
Author

arnaldur commented Feb 8, 2022

This was a bit of a shot in the dark, easier to change this than karapace. But I agree, karapace has had an open issue for a long time on this, it should be fixed there. I will close this and create an issue, I can contribute if you want to support karapace as well.

@arnaldur arnaldur closed this Feb 8, 2022
@arnaldur arnaldur mentioned this pull request Feb 8, 2022
@arnaldur arnaldur reopened this Feb 8, 2022
@AtakanColak
Copy link
Collaborator

I'd prefer to extend the existing interface and struct to a new KarapaceSchemaRegistryClient struct within this repository instead of adding exceptional cases to the existing struct for an exception like this PR. However I'd be up for this only if there are many who use Karapace and this library.

If Schema Registry API omits references if there are no references, then we can use this PR, but I don't know if that is the case.

@arnaldur
Copy link
Author

I understand,I tried to do a minimally invasive change just to support this. I'll close this for now, but willing to put in the time to implement this if the Karapace support question becomes loud.

@arnaldur arnaldur closed this Feb 14, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants