mosche commented on a change in pull request #16503:
URL: https://github.com/apache/beam/pull/16503#discussion_r789825398
##########
File path:
sdks/java/io/amazon-web-services2/src/main/java/org/apache/beam/sdk/io/aws2/sns/SnsIO.java
##########
@@ -370,13 +365,11 @@ private static boolean isTopicExists(SnsClient client,
String topicArn) {
@Override
public PCollection<PublishResponse> expand(PCollection<T> input) {
- checkArgument(getTopicArn() != null, "withTopicArn() is required");
- checkArgument(getPublishRequestFn() != null, "withPublishRequestFn() is
required");
+ checkArgument(getPublishRequestBuilder() != null,
"withPublishRequestBuilder() is required");
Review comment:
The old interface is still there and `withPublishRequestFn()` was
previously required. It now set's the `publishRequestBuilder`. So no breaking
change ...
```java
@Deprecated
public Write<T> withPublishRequestFn(SerializableFunction<T,
PublishRequest> publishRequestFn) {
return builder().setPublishRequestBuilder(m ->
publishRequestFn.apply(m).toBuilder()).build();
}
```
--
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]