[ 
https://issues.apache.org/jira/browse/BEAM-13416?focusedWorklogId=735483&page=com.atlassian.jira.plugin.system.issuetabpanels:worklog-tabpanel#worklog-735483
 ]

ASF GitHub Bot logged work on BEAM-13416:
-----------------------------------------

                Author: ASF GitHub Bot
            Created on: 02/Mar/22 18:37
            Start Date: 02/Mar/22 18:37
    Worklog Time Spent: 10m 
      Work Description: mosche commented on pull request #16947:
URL: https://github.com/apache/beam/pull/16947#issuecomment-1057255231


   > But the getter methods are public, right?
   
   There's public getters of course, but  not following the "getX" naming 
convention. 
   
   I've also looked briefly at just extending `GetterBasedSchemaProvider`, that 
works really well actually. The read part is rather trivial. The field metadata 
of each SDK model provides an easy way to read fields (without any reflection 
involved).
   
   ```java
   static class SdkFieldValueGetter<ObjectT, ValueT> implements 
FieldValueGetter<ObjectT, ValueT> {
       private final SdkField<ValueT> field;
   
       public SdkFieldValueGetter(SdkField<ValueT> field) {
         this.field = field;
       }
   
       @Override
       @Nullable
       public ValueT get(ObjectT object) {
         return field.getValueOrDefault(object);
       }
   
       @Override
       public String name() {
         return field.memberName();
       }
     }
   ```
   
   > Recursive type hierarchies are also definitely support.
   
   Problem with recursive types is the immutable `Schema`. I'm not aware of any 
way to generate such a schema for a recursive hierarchy ... same problem exists 
for `FieldValueTypeInformation`.
   Just verified it quickly, I get a stackoverflow as expected ... so recursive 
types are definitely not supported.
   
   
   


-- 
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.

To unsubscribe, e-mail: [email protected]

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


Issue Time Tracking
-------------------

    Worklog Id:     (was: 735483)
    Time Spent: 2h  (was: 1h 50m)

> SqsIO.write input / construction of Sqs request
> -----------------------------------------------
>
>                 Key: BEAM-13416
>                 URL: https://issues.apache.org/jira/browse/BEAM-13416
>             Project: Beam
>          Issue Type: Improvement
>          Components: io-java-aws
>            Reporter: Moritz Mack
>            Priority: P2
>              Labels: aws, aws-sdk-v2, sqs
>          Time Spent: 2h
>  Remaining Estimate: 0h
>
> SqsIO.write should support arbitrary types T and be implemented in terms of a 
> mapper function that converts T into an AWS request.
> The current implementation of write as 
> {{PTransform<PCollection<SendMessageRequest>, PDone>}} is a rather poor 
> choice. It may requires an additional unnecessary serialization & 
> deserialisation round. But even worse, the current 
> {{SendMessageRequestCoder}} does not support any advanced configuration 
> beyond queueUrl and messageBody and will silently drop it without even 
> warning the user.



--
This message was sent by Atlassian Jira
(v8.20.1#820001)

Reply via email to