zeshuai007 commented on pull request #880:
URL: https://github.com/apache/avro/pull/880#issuecomment-637479024


   Hi @steven-aerts ,
   
   Thank you for your time. For this issue, I investigated the relevant 
specifications.
   The specifications of union are:
   ```
   fail with two branches of the same unnamed type
   succeed with two branches of the same named type, if different names
   ```
   If you use the same named type, the union type of two branches with 
different names, and then use the alias to associate the name, this will 
rewrite the writer's schema with the alias from the reader's schema, 
   ```
   Rewrite a writer's schema using the aliases from a reader's schema. 
Thispermits reading records, 
   enums and fixed schemas whose names have changed,and records whose field 
names have changed. The returned schema alwayscontains the same data elements 
in the same order, but with 
   possiblydifferent names.
   ```
   so that the two branches will be identical, so it violates Failed due to 
union specifications.
   
   If you want to support 
[AVRO-1347](https://issues.apache.org/jira/browse/AVRO-1347) a similar 
solution, I think the specification should be redefined first. Because this 
modification will ignore all union+ aliases checks, this is a violation of the 
specificatio.


----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to