Add config and header support for confluent schema registry. #10314
Add config and header support for confluent schema registry. #10314clintropolis merged 14 commits intoapache:masterfrom spinatelli:Druid-8806
Conversation
…ncies for integration-tests
| int length = bytes.limit() - 1 - 4; | ||
| int offset = bytes.position() + bytes.arrayOffset(); | ||
| Schema schema = registry.getByID(id); | ||
| Schema schema = registry.getById(id); |
There was a problem hiding this comment.
it seems like this method is deprecated as well, but it doesn't really seem like there is a better replacement since the underlying method is doing this
ParsedSchema schema = this.getSchemaById(id);
return schema instanceof AvroSchema ? ((AvroSchema)schema).rawSchema() : null;
There was a problem hiding this comment.
Updated to use getSchemaById, which is anyway overridden by the CachedSchemaRegistryClient implementation that is being used here.
EDIT: actually just used that piece of code, it makes more sense I think, in case getById() gets changed in the future
Co-authored-by: Clint Wylie <cjwylie@gmail.com>
clintropolis
left a comment
There was a problem hiding this comment.
lgtm, thanks @spinatelli 👍
|
Hello all, |
|
Yea something like that would be the next step, I might look into it in the next week |
(porting code from #9096)
Fixes #8806.
Description
This is an update to the code in PR 9096 (#9096), since it's stale. I report the original description and the changes I made
Enhancing schema registry client i.e. SchemaRegistryBasedAvroBytesDecoder to accept additional configs, headers and able to query schemas from multi schema registry instances.
Key changed/added classes in this PR
This PR has:
Key changed/added classes in this PR
SchemaRegistryBasedAvroBytesDecoderSchemaRegistryBasedAvroBytesDecoderTest