the-other-tim-brown commented on code in PR #13136:
URL: https://github.com/apache/hudi/pull/13136#discussion_r2041289064
##########
hudi-hadoop-common/src/main/java/org/apache/hudi/common/util/HFileUtils.java:
##########
@@ -232,6 +232,19 @@ public byte[] serializeRecordsToLogBlock(HoodieStorage
storage,
return baos.toByteArray();
}
+ /**
+ * Print the meta fields of the record of interest
+ */
+ private void printRecord(String msg, byte[] bs, Schema schema) throws
IOException {
+ GenericRecord record = HoodieAvroUtils.bytesToAvro(bs, schema);
+ if (schema.getField(HoodieRecord.RECORD_KEY_METADATA_FIELD) != null) {
+ LOG.error(String.format("%s: Hudi meta field values -> Record key: %s,
Partition Path: %s, FileName: %s, CommitTime: %s, CommitSeqNo: %s", msg,
Review Comment:
Can you use `{}` to follow the logging best practices. The `toString` can
also be removed
--
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]