ahmedabu98 commented on code in PR #31608:
URL: https://github.com/apache/beam/pull/31608#discussion_r1779100320
##########
runners/google-cloud-dataflow-java/src/main/java/org/apache/beam/runners/dataflow/DataflowRunner.java:
##########
@@ -2033,6 +2034,14 @@ private static void translate(
PubsubUnboundedSink overriddenTransform,
StepTranslationContext stepContext,
PCollection input) {
+ if (overriddenTransform.getPublishBatchWithOrderingKey()) {
+ throw new UnsupportedOperationException(
+ String.format(
+ "The DataflowRunner does not currently support publishing to
Pubsub with ordering keys. "
+ + "%s is required to support publishing with ordering
keys. "
+ + "Set the pipeline option --experiments=%s to use this
PTransform.",
Review Comment:
Done
##########
sdks/java/io/google-cloud-platform/src/main/java/org/apache/beam/sdk/io/gcp/pubsub/PubsubIO.java:
##########
@@ -1382,6 +1384,8 @@ abstract Builder<T> setFormatFn(
abstract Builder<T> setPubsubRootUrl(String pubsubRootUrl);
+ abstract Builder<T> setNeedsOrderingKey(boolean needsOrderingKey);
Review Comment:
That's fair, switched it to `publishWithOrderingKey`
--
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]