Commit 38181be
fix(connector): normalize non-shaded Avro collections nested inside a shaded UDT
Next layer of the testSchema shaded/non-shaded Avro tolerance. After the
top-level array/map fixes, testSchema failed at:
assertField:857 (cast to shaded GenericData$Array)
<- assertGenericRecords:903 (udt field)
<- assertField:853 (yudt)
Pulsar returns a top-level UDT (yudt) as a SHADED GenericRecord, but the
collection fields nested inside it (the UDT's zlist/zset) still come back as
NON-shaded Avro arrays. normalizeToShadedAvro is a no-op on the already-shaded
record, so those nested arrays were never converted and the shaded-typed
assertion threw.
Wrap the per-field extraction in assertGenericRecords' udt/udtoptional cases
with normalizeToShadedAvro so each nested value is converted before asserting.
(Collections nested inside ysetofudt are already handled: that whole array is
deep-converted to shaded by the binary round-trip.)
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>1 parent c733f0d commit 38181be
1 file changed
Lines changed: 5 additions & 2 deletions
Lines changed: 5 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
899 | 899 | | |
900 | 900 | | |
901 | 901 | | |
| 902 | + | |
| 903 | + | |
| 904 | + | |
902 | 905 | | |
903 | | - | |
| 906 | + | |
904 | 907 | | |
905 | 908 | | |
906 | 909 | | |
907 | 910 | | |
908 | 911 | | |
909 | 912 | | |
910 | | - | |
| 913 | + | |
911 | 914 | | |
912 | 915 | | |
913 | 916 | | |
| |||
0 commit comments