public class LogTruncationException extends OffsetOutOfRangeException
| Constructor and Description |
|---|
LogTruncationException(String message,
Map<TopicPartition,Long> fetchOffsets,
Map<TopicPartition,OffsetAndMetadata> divergentOffsets) |
| Modifier and Type | Method and Description |
|---|---|
Map<TopicPartition,OffsetAndMetadata> |
divergentOffsets()
Get the divergent offsets for the partitions which were truncated.
|
offsetOutOfRangePartitions, partitionsaddSuppressed, fillInStackTrace, getCause, getLocalizedMessage, getMessage, getStackTrace, getSuppressed, initCause, printStackTrace, printStackTrace, printStackTrace, setStackTrace, toStringpublic LogTruncationException(String message, Map<TopicPartition,Long> fetchOffsets, Map<TopicPartition,OffsetAndMetadata> divergentOffsets)
public Map<TopicPartition,OffsetAndMetadata> divergentOffsets()
OffsetOutOfRangeException.partitions() to see the set of partitions that were truncated
and then check for the presence of a divergent offset in this map.