public abstract static class SnsIO.Write<T> extends PTransform<PCollection<T>,PCollection<PublishResponse>>
SnsIO.write().name, resourceHints| Constructor and Description |
|---|
Write() |
| Modifier and Type | Method and Description |
|---|---|
PCollection<PublishResponse> |
expand(PCollection<T> input)
Override this method to specify how this
PTransform should be expanded on the given
InputT. |
SnsIO.Write<T> |
withClientConfiguration(ClientConfiguration config)
Configuration of SNS client.
|
SnsIO.Write<T> |
withCoder(Coder<PublishResponse> coder)
Deprecated.
Explicit usage of coders is deprecated. Inferred schemas provided by
AwsSchemaProvider will be used instead. |
SnsIO.Write<T> |
withFullPublishResponse()
Deprecated.
Writes fail exceptionally in case of errors, there is no need to check headers.
|
SnsIO.Write<T> |
withFullPublishResponseWithoutHeaders()
Deprecated.
Writes fail exceptionally in case of errors, there is no need to check headers.
|
SnsIO.Write<T> |
withPublishRequestBuilder(SerializableFunction<T,PublishRequest.Builder> requestBuilder)
Function to convert a message into a
PublishRequest.Builder (mandatory). |
SnsIO.Write<T> |
withPublishRequestFn(SerializableFunction<T,PublishRequest> publishRequestFn)
Deprecated.
Use
withPublishRequestBuilder(SerializableFunction) instead. |
SnsIO.Write<T> |
withRetryConfiguration(SnsIO.RetryConfiguration retry)
Deprecated.
Use
withClientConfiguration(ClientConfiguration) with RetryConfiguration instead to delegate retries to the
AWS SDK. |
SnsIO.Write<T> |
withSnsClientProvider(AwsCredentialsProvider credentials,
java.lang.String region)
Deprecated.
Use
withClientConfiguration(ClientConfiguration) instead. |
SnsIO.Write<T> |
withSnsClientProvider(AwsCredentialsProvider credentials,
java.lang.String region,
java.net.URI endpoint)
Deprecated.
Use
withClientConfiguration(ClientConfiguration) instead. |
SnsIO.Write<T> |
withSnsClientProvider(SnsClientProvider clientProvider)
Deprecated.
Use
withClientConfiguration(ClientConfiguration) instead. Alternatively
you can configure a custom ClientBuilderFactory in AwsOptions. |
SnsIO.Write<T> |
withTopicArn(java.lang.String topicArn)
SNS topic ARN used for publishing to SNS.
|
compose, compose, getAdditionalInputs, getDefaultOutputCoder, getDefaultOutputCoder, getDefaultOutputCoder, getKindString, getName, getResourceHints, populateDisplayData, setResourceHints, toString, validate, validatepublic SnsIO.Write<T> withTopicArn(java.lang.String topicArn)
The topic ARN is optional. If set, its existence will be validated and the SNS publish request will be configured accordingly.
public SnsIO.Write<T> withPublishRequestBuilder(SerializableFunction<T,PublishRequest.Builder> requestBuilder)
PublishRequest.Builder (mandatory).
If an SNS topic arn is set, it will be automatically set on the PublishRequest.Builder.
@Deprecated public SnsIO.Write<T> withPublishRequestFn(SerializableFunction<T,PublishRequest> publishRequestFn)
withPublishRequestBuilder(SerializableFunction) instead.@Deprecated public SnsIO.Write<T> withSnsClientProvider(SnsClientProvider clientProvider)
withClientConfiguration(ClientConfiguration) instead. Alternatively
you can configure a custom ClientBuilderFactory in AwsOptions.@Deprecated public SnsIO.Write<T> withSnsClientProvider(AwsCredentialsProvider credentials, java.lang.String region)
withClientConfiguration(ClientConfiguration) instead.@Deprecated public SnsIO.Write<T> withSnsClientProvider(AwsCredentialsProvider credentials, java.lang.String region, java.net.URI endpoint)
withClientConfiguration(ClientConfiguration) instead.public SnsIO.Write<T> withClientConfiguration(ClientConfiguration config)
@Deprecated public SnsIO.Write<T> withRetryConfiguration(SnsIO.RetryConfiguration retry)
withClientConfiguration(ClientConfiguration) with RetryConfiguration instead to delegate retries to the
AWS SDK.@Deprecated public SnsIO.Write<T> withFullPublishResponse()
PublishResponse object, including sdkResponseMetadata and
sdkHttpMetadata with the HTTP response headers.@Deprecated public SnsIO.Write<T> withFullPublishResponseWithoutHeaders()
PublishResponse object, including sdkResponseMetadata and
sdkHttpMetadata but excluding the HTTP response headers.@Deprecated public SnsIO.Write<T> withCoder(Coder<PublishResponse> coder)
AwsSchemaProvider will be used instead.PublishResponse with the given coder.public PCollection<PublishResponse> expand(PCollection<T> input)
PTransformPTransform should be expanded on the given
InputT.
NOTE: This method should not be called directly. Instead apply the PTransform should
be applied to the InputT using the apply method.
Composite transforms, which are defined in terms of other transforms, should return the output of one of the composed transforms. Non-composite transforms, which do not apply any transforms internally, should return a new unbound output and register evaluators (via backend-specific registration methods).
expand in class PTransform<PCollection<T>,PCollection<PublishResponse>>