@Internal public class KafkaTopicPartitionStateSentinel extends Object
The values are all negative. Negative offsets are not used by Kafka (invalid), so we pick a number that is probably (hopefully) not used by Kafka as a magic number for anything else.
| 限定符和类型 | 字段和说明 |
|---|---|
static long |
EARLIEST_OFFSET
Magic number that defines the partition should start from the earliest offset.
|
static long |
GROUP_OFFSET
Magic number that defines the partition should start from its committed group offset in
Kafka.
|
static long |
LATEST_OFFSET
Magic number that defines the partition should start from the latest offset.
|
static long |
OFFSET_NOT_SET
Magic number that defines an unset offset.
|
| 构造器和说明 |
|---|
KafkaTopicPartitionStateSentinel() |
public static final long OFFSET_NOT_SET
public static final long EARLIEST_OFFSET
This is used as a placeholder so that the actual earliest offset can be evaluated lazily when the partition will actually start to be read by the consumer.
public static final long LATEST_OFFSET
This is used as a placeholder so that the actual latest offset can be evaluated lazily when the partition will actually start to be read by the consumer.
public static final long GROUP_OFFSET
This is used as a placeholder so that the actual committed group offset can be evaluated lazily when the partition will actually start to be read by the consumer.
Copyright © 2014–2023 The Apache Software Foundation. All rights reserved.