[ 
https://issues.apache.org/jira/browse/AVRO-3683?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17656087#comment-17656087
 ] 

ASF subversion and git services commented on AVRO-3683:
-------------------------------------------------------

Commit 2f54f23c806a98aea8c9449615890b875f685ed4 in avro's branch 
refs/heads/avro-3683-multiple-schemas from Martin Tzvetanov Grigorov
[ https://gitbox.apache.org/repos/asf?p=avro.git;h=2f54f23c8 ]

AVRO-3683: WIP

Add support for multiple schemata in Reader/Writer APIs

Signed-off-by: Martin Tzvetanov Grigorov <[email protected]>


> Rust  Writer, Reader can't use Schemas with dependencies in other Schemas.   
> i.e. The output of Schema::parse_list 
> -------------------------------------------------------------------------------------------------------------------
>
>                 Key: AVRO-3683
>                 URL: https://issues.apache.org/jira/browse/AVRO-3683
>             Project: Apache Avro
>          Issue Type: Bug
>          Components: rust
>    Affects Versions: 1.11.1
>            Reporter: Mark Farnan
>            Priority: Major
>              Labels: pull-request-available
>          Time Spent: 2h 20m
>  Remaining Estimate: 0h
>
> Avro permits Schema definitions to reference Types defined in other Schema 
> files. 
> Currently these can be parsed with Schema:parse_list, but the output of this 
> can't be used in Writer, Reader,  (or to_avro_datum,  from_avro_datum)
>  * These functions only take a single 'schema' and can't resolve the 
> References
>  * Schema:parse_list puts in 'refs' for the external dependencies, but 
> doesn't seem to populate the UnionSchema's, so they can be resolved.
>  
> +Example of dependant schemas:+
> letschema_TypeA=r#"
> {
> "type": "record",
> "namespace": "base.name.space",
> "name": "MultiSchemaTestTypeA",
> "fields":
> [
> { "name": "b", "type": ["null", "some.name.space.MultiSchemaTestTypeB"] }
> ,
> { "name": "c", "type": \\{ "type": "map", "values": 
> "some.name.space.MultiSchemaTestTypeB" }
> , "default": {}
> }
> ]
> }
> "#;
> letschema_TypeB=r#"
> {
> "type": "record",
> "namespace": "some.name.space",
> "name": "MultiSchemaTestTypeB",
> "fields":
> [
> { "name": "d", "type": "string" }
> ,
> { "name": "e", "type": "int" }
> ]
> }
> "#;
>  
> PR Created with a failing test:  https://github.com/apache/avro/pull/1997



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to