kennknowles commented on a change in pull request #14917:
URL: https://github.com/apache/beam/pull/14917#discussion_r644119288
##########
File path:
sdks/java/io/google-cloud-platform/src/main/java/org/apache/beam/sdk/io/gcp/pubsublite/CloudPubsubTransforms.java
##########
@@ -48,4 +49,21 @@ private CloudPubsubChecks() {}
return message;
});
}
+
+ /**
+ * Transform messages read from Pub/Sub Lite to their equivalent Cloud
Pub/Sub Message that would
+ * have been read from PubsubIO.
+ *
+ * <p>Will fail the pipeline if a message has multiple attributes per map
key.
+ */
+ public static PTransform<PCollection<? extends SequencedMessage>,
PCollection<PubsubMessage>>
Review comment:
Can you write this as a composite transform? Same logic, but in the
`expand` method. A bit of boilerplate that helps out UIs and metrics, etc.
--
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.
For queries about this service, please contact Infrastructure at:
[email protected]