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

Does the "name" argument to "addReference" and "addLocalReference" do anything when using Avro schemas? #171

Closed
adaptivecchinitz opened this issue Feb 14, 2024 · 2 comments
Labels
question Further information is requested

Comments

@adaptivecchinitz
Copy link

adaptivecchinitz commented Feb 14, 2024

It appears that I can type whatever I want for the name, and the task still resolves the references and registers my schemas just fine.

I took a quick look in the source code, and don't think I saw the name used in the Avro schema parser, only in the Json schema parser.

Am I missing a spot that uses the name when working with Avro? If the name matters, I'd like to make sure I set it correctly.

Thanks!


And thanks, in general, for your work on this plugin! It's very useful!

@ImFlog
Copy link
Owner

ImFlog commented Feb 15, 2024

Hello @adaptivecchinitz thank you for using this plugin and the kind words 🙇

The Subject name is required for remote references by the Schema Registry client. IIRC it's the name that will be registered in the Schema Registry.
For the local reference in Avro you are probably right, it doesn't seem to be used with the custom Avro implementation. I am planning to try to improve the local schema parsing (see #162) and that may change. Also I don't want to add a breaking change on the Subject and I kinda like the consistency of the API even for distinct Schema type.
So It will probably stay like this for now.

Thank you for pointing that 🙏

@ImFlog ImFlog closed this as completed Feb 15, 2024
@ImFlog ImFlog added the question Further information is requested label Feb 15, 2024
@adaptivecchinitz
Copy link
Author

Ok, I'll probably leave the name argument as an empty string, then, which works fine for me. Thanks for the quick reply!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question Further information is requested
Projects
None yet
Development

No branches or pull requests

2 participants