You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@flink.apache.org by GitBox <gi...@apache.org> on 2020/07/22 16:43:25 UTC
[GitHub] [flink] gaoyunhaii commented on pull request #8357: [FLINK-12175] Change filling of typeHierarchy in analyzePojo, for cor…
gaoyunhaii commented on pull request #8357:
URL: https://github.com/apache/flink/pull/8357#issuecomment-662562203
Very thanks @andbul and @dawidwys for the PR! I also agree with that we could remove the condition and always compute the type hierarchy. There are cases that the hierarchy get repeated, for example, if we have
```
class MyTuple extends Tuple2<String, String>{
public String anotherField;
}
```
We will first try to analyze it as a Tuple and calculated the hierarchy from MyTuple -> Tuple2, however we will fail since it has additional fields, the we will turn to `analyzePojo` and if we calculated the hierarchy from MyTuple -> Object again, the hierarchy will be repeated.
However, I don't think the repeating will cause errors. Besides, it is hard to detect if there are repeating with the number of hierarchy, since MyTuple -> Object may have arbitrary numbers of types.
I also left some comments for the tests.
----------------------------------------------------------------
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:
users@infra.apache.org