thiagotnunes commented on code in PR #22769:
URL: https://github.com/apache/beam/pull/22769#discussion_r948555250


##########
sdks/java/io/google-cloud-platform/src/main/java/org/apache/beam/sdk/io/gcp/spanner/changestreams/mapper/ChangeStreamRecordMapper.java:
##########
@@ -253,6 +255,8 @@ private DataChangeRecord toDataChangeRecord(
         valueCaptureTypeFrom(row.getString(VALUE_CAPTURE_TYPE_COLUMN)),
         row.getLong(NUMBER_OF_RECORDS_IN_TRANSACTION_COLUMN),
         row.getLong(NUMBER_OF_PARTITIONS_IN_TRANSACTION_COLUMN),
+        row.getString(TRANSACTION_TAG),

Review Comment:
   Are these always present or can they be `null`? If the latter is true, you 
have to do `row.isNull(TRANSACTION_TAG) ? null : row.getString(TRANSACTION_TAG)`



##########
sdks/java/io/google-cloud-platform/src/test/java/org/apache/beam/sdk/io/gcp/spanner/changestreams/mapper/ChangeStreamRecordMapperTest.java:
##########
@@ -99,6 +99,8 @@ public void testMappingUpdateStructRowToDataChangeRecord() {
             ValueCaptureType.OLD_AND_NEW_VALUES,
             10L,
             2L,
+            "transactionTag",

Review Comment:
   If the transaction tag could be null, could you add a test?



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