mahagen commented on code in PR #25644:
URL: https://github.com/apache/beam/pull/25644#discussion_r1134570932


##########
sdks/java/io/google-cloud-platform/src/main/java/org/apache/beam/sdk/io/gcp/pubsublite/PubsubLiteReadSchemaTransformProvider.java:
##########
@@ -61,13 +68,19 @@
   @Override
   public @UnknownKeyFor @NonNull @Initialized SchemaTransform from(
       PubsubLiteReadSchemaTransformConfiguration configuration) {
+    if (!VALID_DATA_FORMATS.contains(configuration.getFormat())) {
+      throw new IllegalArgumentException(
+          String.format(
+              "Format %s not supported. Only supported formats are %s",
+              configuration.getFormat(), VALID_FORMATS_STR));

Review Comment:
   If the format string is used here, then the comma in VALID_FORMATS_STR 
should have a space after it. 



-- 
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]

Reply via email to