Class ReporterBackedMapReduceDataWriterTaskTracker
java.lang.Object
com.linkedin.venice.hadoop.mapreduce.datawriter.task.ReporterBackedMapReduceDataWriterTaskTracker
- All Implemented Interfaces:
DataWriterTaskTracker,TaskTracker
public class ReporterBackedMapReduceDataWriterTaskTracker
extends Object
implements DataWriterTaskTracker
An interface to report and retrieve metrics related to data writer tasks during the execution of a MapReduce job.
-
Field Summary
Fields inherited from interface com.linkedin.venice.hadoop.task.TaskTracker
PROGRESS_COMPLETED, PROGRESS_NOT_SUPPORTED -
Constructor Summary
ConstructorsConstructorDescriptionReporterBackedMapReduceDataWriterTaskTracker(org.apache.hadoop.mapred.Reporter reporter) -
Method Summary
Modifier and TypeMethodDescriptionlonglongReturns the set of regions whose external writers exhausted retries and were reported by one or more data-writer tasks.longfloatGet the progress of the task.longorg.apache.hadoop.mapred.ReporterlonglonglonglonglonglongvoidReport task heartbeat if the execution engine requires itvoidtrackCompressedValueSize(int size) voidtrackDuplicateKeyWithDistinctValue(int count) voidtrackDuplicateKeyWithIdenticalValue(int count) voidvoidtrackExternalStorageWriteTime(long timeMs) Report elapsed wall-clock time this task spent inside the external-storage write path.voidtrackFailedExternalStorageRegion(String regionName) Report that the external writer forregionNameexhausted its retry budget and was disabled for the remainder of the task.voidtrackGzipCompressedValueSize(int size) voidtrackIncrementalPushThrottledTime(long timeMs) voidtrackKeySize(int size) voidvoidvoidvoidvoidvoidvoidvoidtrackUncompressedValueSize(int size) voidtrackVeniceWriteTime(long timeMs) Report elapsed wall-clock time this task spent invoking the Venice/Kafka write path: theVeniceWriter.putinvocations plus flushing and closing the Venice writer.voidvoidtrackZstdCompressedValueSize(int size) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.linkedin.venice.hadoop.task.datawriter.DataWriterTaskTracker
getLargestUncompressedValueSize, getOutputRecordsCount, getPartitionWriterCloseCount, getPerPartitionRecordCounts, getRepushTtlFilterCount, getSprayAllPartitionsCount, getTotalGzipCompressedValueSize, getTotalUncompressedValueSize, getTotalZstdCompressedValueSize, trackLargestUncompressedValueSize
-
Constructor Details
-
ReporterBackedMapReduceDataWriterTaskTracker
public ReporterBackedMapReduceDataWriterTaskTracker(org.apache.hadoop.mapred.Reporter reporter)
-
-
Method Details
-
getReporter
public org.apache.hadoop.mapred.Reporter getReporter() -
heartbeat
public void heartbeat()Description copied from interface:TaskTrackerReport task heartbeat if the execution engine requires it- Specified by:
heartbeatin interfaceTaskTracker
-
getProgress
public float getProgress()Description copied from interface:TaskTrackerGet the progress of the task. If the engine supports fetching the progress, progress is represented as a number between 0 and 1 (inclusive). If the engine doesn't support fetching the progress, a value of -1 is returned.- Specified by:
getProgressin interfaceTaskTracker
-
trackSprayAllPartitions
public void trackSprayAllPartitions()- Specified by:
trackSprayAllPartitionsin interfaceDataWriterTaskTracker
-
trackEmptyRecord
public void trackEmptyRecord()- Specified by:
trackEmptyRecordin interfaceDataWriterTaskTracker
-
trackKeySize
public void trackKeySize(int size) - Specified by:
trackKeySizein interfaceDataWriterTaskTracker
-
trackUncompressedValueSize
public void trackUncompressedValueSize(int size) - Specified by:
trackUncompressedValueSizein interfaceDataWriterTaskTracker
-
trackCompressedValueSize
public void trackCompressedValueSize(int size) - Specified by:
trackCompressedValueSizein interfaceDataWriterTaskTracker
-
trackGzipCompressedValueSize
public void trackGzipCompressedValueSize(int size) - Specified by:
trackGzipCompressedValueSizein interfaceDataWriterTaskTracker
-
trackZstdCompressedValueSize
public void trackZstdCompressedValueSize(int size) - Specified by:
trackZstdCompressedValueSizein interfaceDataWriterTaskTracker
-
trackWriteAclAuthorizationFailure
public void trackWriteAclAuthorizationFailure()- Specified by:
trackWriteAclAuthorizationFailurein interfaceDataWriterTaskTracker
-
trackRecordTooLargeFailure
public void trackRecordTooLargeFailure()- Specified by:
trackRecordTooLargeFailurein interfaceDataWriterTaskTracker
-
trackUncompressedRecordTooLargeFailure
public void trackUncompressedRecordTooLargeFailure()- Specified by:
trackUncompressedRecordTooLargeFailurein interfaceDataWriterTaskTracker
-
trackRecordSentToPubSub
public void trackRecordSentToPubSub()- Specified by:
trackRecordSentToPubSubin interfaceDataWriterTaskTracker
-
trackDuplicateKeyWithDistinctValue
public void trackDuplicateKeyWithDistinctValue(int count) - Specified by:
trackDuplicateKeyWithDistinctValuein interfaceDataWriterTaskTracker
-
trackDuplicateKeyWithIdenticalValue
public void trackDuplicateKeyWithIdenticalValue(int count) - Specified by:
trackDuplicateKeyWithIdenticalValuein interfaceDataWriterTaskTracker
-
trackRepushTtlFilteredRecord
public void trackRepushTtlFilteredRecord()- Specified by:
trackRepushTtlFilteredRecordin interfaceDataWriterTaskTracker
-
trackPartitionWriterClose
public void trackPartitionWriterClose()- Specified by:
trackPartitionWriterClosein interfaceDataWriterTaskTracker
-
trackPutOrDeleteRecord
public void trackPutOrDeleteRecord()- Specified by:
trackPutOrDeleteRecordin interfaceDataWriterTaskTracker
-
trackIncrementalPushThrottledTime
public void trackIncrementalPushThrottledTime(long timeMs) - Specified by:
trackIncrementalPushThrottledTimein interfaceDataWriterTaskTracker
-
trackFailedExternalStorageRegion
Description copied from interface:DataWriterTaskTrackerReport that the external writer forregionNameexhausted its retry budget and was disabled for the remainder of the task. Callers should report each region at most once per task.- Specified by:
trackFailedExternalStorageRegionin interfaceDataWriterTaskTracker
-
getIncrementalPushThrottledTimeMs
public long getIncrementalPushThrottledTimeMs()- Specified by:
getIncrementalPushThrottledTimeMsin interfaceDataWriterTaskTracker
-
trackExternalStorageWriteTime
public void trackExternalStorageWriteTime(long timeMs) Description copied from interface:DataWriterTaskTrackerReport elapsed wall-clock time this task spent inside the external-storage write path. This covers the complete external leg: the per-region write throttling wait, theExternalStorageWriter.batchPutcalls including their retries and retry backoff sleeps, the externalflush, and the externalclose. It excludes anything spent producing to Venice/Kafka.Callers report monotonic deltas as they accrue, so the aggregate is the sum of per-task durations, not the push's wall-clock duration: with N concurrent data-writer tasks the total can be up to N times the push's elapsed time.
- Specified by:
trackExternalStorageWriteTimein interfaceDataWriterTaskTracker
-
trackVeniceWriteTime
public void trackVeniceWriteTime(long timeMs) Description copied from interface:DataWriterTaskTrackerReport elapsed wall-clock time this task spent invoking the Venice/Kafka write path: theVeniceWriter.putinvocations plus flushing and closing the Venice writer. It excludes anything spent in the external-storage path.Same aggregation semantics as
DataWriterTaskTracker.trackExternalStorageWriteTime(long): summed task durations, not push wall-clock time.- Specified by:
trackVeniceWriteTimein interfaceDataWriterTaskTracker
-
getExternalStorageWriteTimeMs
public long getExternalStorageWriteTimeMs()- Specified by:
getExternalStorageWriteTimeMsin interfaceDataWriterTaskTracker- Returns:
- the summed per-task duration (ms) spent in the external-storage write path across all successful
task outputs of this push. See
DataWriterTaskTracker.trackExternalStorageWriteTime(long)for exactly what is included; this is not the push's wall-clock time.
-
getVeniceWriteTimeMs
public long getVeniceWriteTimeMs()- Specified by:
getVeniceWriteTimeMsin interfaceDataWriterTaskTracker- Returns:
- the summed per-task duration (ms) spent in the Venice/Kafka write path across all successful task
outputs of this push. See
DataWriterTaskTracker.trackVeniceWriteTime(long); this is not the push's wall-clock time.
-
getTotalKeySize
public long getTotalKeySize()- Specified by:
getTotalKeySizein interfaceDataWriterTaskTracker
-
getTotalValueSize
public long getTotalValueSize()- Specified by:
getTotalValueSizein interfaceDataWriterTaskTracker
-
getRecordTooLargeFailureCount
public long getRecordTooLargeFailureCount()- Specified by:
getRecordTooLargeFailureCountin interfaceDataWriterTaskTracker
-
getUncompressedRecordTooLargeFailureCount
public long getUncompressedRecordTooLargeFailureCount()- Specified by:
getUncompressedRecordTooLargeFailureCountin interfaceDataWriterTaskTracker
-
getWriteAclAuthorizationFailureCount
public long getWriteAclAuthorizationFailureCount()- Specified by:
getWriteAclAuthorizationFailureCountin interfaceDataWriterTaskTracker
-
getDuplicateKeyWithDistinctValueCount
public long getDuplicateKeyWithDistinctValueCount()- Specified by:
getDuplicateKeyWithDistinctValueCountin interfaceDataWriterTaskTracker
-
getTotalPutOrDeleteRecordsCount
public long getTotalPutOrDeleteRecordsCount()- Specified by:
getTotalPutOrDeleteRecordsCountin interfaceDataWriterTaskTracker
-
getFailedExternalStorageRegions
Description copied from interface:DataWriterTaskTrackerReturns the set of regions whose external writers exhausted retries and were reported by one or more data-writer tasks. Implementations should return an immutable or defensive-copy snapshot.- Specified by:
getFailedExternalStorageRegionsin interfaceDataWriterTaskTracker
-