nbalajee commented on a change in pull request #2607:
URL: https://github.com/apache/hudi/pull/2607#discussion_r595527355
##########
File path:
hudi-client/hudi-client-common/src/main/java/org/apache/hudi/config/HoodieWriteConfig.java
##########
@@ -143,6 +143,9 @@
public static final String CLIENT_HEARTBEAT_NUM_TOLERABLE_MISSES_PROP =
"hoodie.client.heartbeat.tolerable.misses";
public static final Integer DEFAULT_CLIENT_HEARTBEAT_NUM_TOLERABLE_MISSES =
2;
+ public static final String COLLECT_OBSERVABILITY_METRICS =
"hoodie.collect.observability.metrics";
+ public static final String DEFAULT_COLLECT_OBSERVABILITY_METRICS = "true";
Review comment:
Done
##########
File path:
hudi-client/hudi-client-common/src/main/java/org/apache/hudi/io/HoodieAppendHandle.java
##########
@@ -377,9 +388,21 @@ public void write(HoodieRecord record,
Option<IndexedRecord> insertValue) {
writer.close();
// update final size, once for all log files
+ long totalLogFileSize = 0;
for (WriteStatus status: statuses) {
long logFileSize = FSUtils.getFileSize(fs, new
Path(config.getBasePath(), status.getStat().getPath()));
status.getStat().setFileSizeInBytes(logFileSize);
+ totalLogFileSize += logFileSize;
+ }
+
+ if (config.isMetricsOn() &&
config.shouldCollectObservabilityMetrics()) {
Review comment:
Done.
----------------------------------------------------------------
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]