[ https://issues.apache.org/jira/browse/BEAM-9326?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17040225#comment-17040225 ]
Ismaël Mejía commented on BEAM-9326: ------------------------------------ Thanks for answering [~kenn] I see the covariant argument makes sense for MapElements since the type is generic, but what I found odd in the case of JsonToRow was that the type accepted was `? extends String` because String is final in Java so for basic definition nobody can inherit String. It is a pretty minor fix, but worth the adjustment for the sake of 'correctness'. > JsonToRow transform should not use bounded Wildcards for its input > ------------------------------------------------------------------ > > Key: BEAM-9326 > URL: https://issues.apache.org/jira/browse/BEAM-9326 > Project: Beam > Issue Type: Improvement > Components: sdk-java-core > Reporter: Ismaël Mejía > Assignee: Ismaël Mejía > Priority: Minor > Fix For: 2.20.0 > > Time Spent: 10m > Remaining Estimate: 0h > > The JsonToRow PTransform input is a String (a final class in Java) so no > reason > to define a bounded wildcard as its argument. > We should use <? extends String> in Beam's codebase only when required by Java > Generics constraints. -- This message was sent by Atlassian Jira (v8.3.4#803005)