marcosschroh / marcosschroh/python-schema-registry-client
support for complex avro schema
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 178
- Forks
- 57
- PR merge metrics
- No merged PRs in 30d
Description
It appears as if the library does not support complex avro schema. That is, avro schema which contain multiple classes referencing each other.
Take the following avro schema, for example:
[{
"name": "Order",
"namespace": "com.questanalytics.core",
"type": "record",
"fields": [{
"name": "uid",
"type": "int",
"default": "NONE"
}]
}, {
"name": "Customer",
"namespace": "com.questanalytics.core",
"type": "record",
"fields": [{
"name": "uid",
"type": "int",
"default": "NONE"
} {
"name": "order",
"type": "Order",
"default": "NONE"
}, {
"name": "name",
"type": "string",
"default": "NONE"
}]
}]
The above has a Customer who has embedded Order objects. Am I wrong in that this library will not allow a developer to work with a schema like this?
We are looking at the writeup here: https://marcosschroh.github.io/python-schema-registry-client/faust/ and it seems as if the faust integration assumes the schema is limited to a single class.
For example, it isn't clear how the following expression (taken from the writeup linked above) could possibly refer to a complex schema:
class UserModel(faust.Record, serializer='avro_users'):
first_name: str
last_name: str
It seems as if it assumes the schema contains one and only one class (User)
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the Faust integration writeup and its UserModel example, then reproduce the reported schema containing Order and Customer records with a reference between them. Done means establishing whether multi-record Avro schemas are supported and, if not, defining the integration behavior and documenting how to use such schemas.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- backend
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100