Details
Description
I cannot seem to find the enum's default attribute as documented in the spec
I'm trying to create an avdl parser and this is a blocker for me. I was wondering if there's a reason for this. Otherwise I can submit a PR, please let me know, thanks.
Code sample:
let schema_str = r#"{"name":"Shapes","type":"enum","symbols":["SQUARE","TRIANGLE","CIRCLE","OVAL"], "default": "SQUARE"}"#; let r = Schema::parse_str(schema_str).unwrap(); let can = r.canonical_form(); println!("{r:?}"); println!("{can}");
Observe the enum in its canonical form is missing the default.
Looking at the Enum's code, we cannot see a default field:
https://github.com/apache/avro/blob/master/lang/rust/avro/src/schema.rs#L113-L119
I apologize if this is somehow wrong
Attachments
Issue Links
- links to