scwhittle commented on code in PR #31608:
URL: https://github.com/apache/beam/pull/31608#discussion_r1760934936


##########
sdks/java/io/google-cloud-platform/src/main/java/org/apache/beam/sdk/io/gcp/pubsub/PreparePubsubWriteDoFn.java:
##########
@@ -193,16 +190,6 @@ public void process(
           .add("pubsub", "topic", 
PubsubClient.topicPathFromPath(topic).getDataCatalogSegments());
       reportedLineage = topic;
     }
-    // TODO: Remove this check once Dataflow's native sink supports ordering 
keys.
-    if (!allowOrderingKey && !Strings.isNullOrEmpty(message.getOrderingKey())) 
{

Review Comment:
   could periodically log that the ordering key is present but will not be used?
   
   We could clear the ordering key in this case so that we don't affect 
batching of publishing unnecessarily.



##########
sdks/java/io/google-cloud-platform/src/main/java/org/apache/beam/sdk/io/gcp/pubsub/PubsubIO.java:
##########
@@ -1543,7 +1543,6 @@ public PDone expand(PCollection<T> input) {
                       new PreparePubsubWriteDoFn<>(
                           getFormatFn(),
                           topicFunction,
-                          getNeedsOrderingKey(),

Review Comment:
   NeedsOrderingKey sounds like it if it is true, that messages without an 
ordering key should not be publishable.  Woudl something like usesOrderingKey 
or publishWithOrderingKey be clearer?



-- 
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: github-unsubscr...@beam.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to