forked from apache/pulsar
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Support passing schema definition for JSON and AVRO schemas (apache#3766
) * Support passing schema definition for JSON and AVRO schemas *Motivation* Currently AVRO and Schema generated schemas from POJO directly. Sometime people would like to use pre-generated/defined schemas, so allow passing in schema definitions would clear the confusions on parsing schemas from POJO. *Modifications* - Abstract a common base class `StructSchema` for AVRO/PROTOBUF/JSON - Standarize on using avro schema for defining schema (we already did that. this change only makes it clearer) - Add methods to pass schema definition for JSON and AVRO schemas *NOTES* We don't support passing schema definition for PROTOBUF. since we only supported generated messages as POJO class for protobuf schema, and we generate schema definition from the generated messages. it doesn't make sense to pass in a different schema definition. * Add missing license header
- Loading branch information
Showing
7 changed files
with
263 additions
and
61 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.