-
-
Notifications
You must be signed in to change notification settings - Fork 55
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
Faust Generic Serializer #108
Comments
I am sorry for the delay. Your feature request makes sense.
I think that this feature will be helpful, but what I would suggest is:
If we follow the ⬆️ steps, you won't need any explicit relationship between |
Hi @marcosschroh,
Happy for this issue to be closed if you feel like this is not within the goals/scope of this project 😊. Much appreciated. |
In a I think that using pre-registered What do you think? |
I concur, obviously you will still need to let the serializer know what class it will be serializing to/from but this can be independent of the actual pre-registered schema. It does raise the question of checks as to whether the schema actually matches the class representation of it. Although you could probably offload that to something like
For |
Feature Request✨
While I may be treating the package incorrectly, it appears that, by intention, there exists one serializer per schema. I was interested in a generic serializer that took any registered
Record
/AvroModel
subclass and attempted to serialize/deserialize it.Additionally the ability to register a specific schema to a confluent kafka topic value/key was desirable.
I quickly whipped up a example:
Record
namespace.register_to_topic
will attempt to register the schema as a confluent topic value or key schema.Considerations 🔍️:
Record
namespace is for model identificationQuestions 🤔:
_loads
and_dumps
must be synchronous due to Faust compatibility, would there be anyway to use anAsyncSchemaRegistryClient
and support async avro writers within these functions?Notes 📝:
The text was updated successfully, but these errors were encountered: