public class SpringXdOffsetManager extends org.springframework.integration.kafka.listener.MetadataStoreOffsetManager implements DeletableOffsetManager
MetadataStoreOffsetManager
with additional features such
as the ability to delete offsets, and recognizing Kafka consumer code for "earliest time"
and "latest time" ("smallest" and "largest" respectively).Modifier and Type | Class and Description |
---|---|
static class |
SpringXdOffsetManager.AutoOffsetResetStrategy |
Modifier and Type | Field and Description |
---|---|
static java.util.regex.Pattern |
VALIDATION_PATTERN |
Constructor and Description |
---|
SpringXdOffsetManager(org.springframework.integration.kafka.core.ConnectionFactory connectionFactory) |
SpringXdOffsetManager(org.springframework.integration.kafka.core.ConnectionFactory connectionFactory,
java.lang.String topic,
java.lang.String initialOffsets)
Creates a
MetadataStoreOffsetManager with |
Modifier and Type | Method and Description |
---|---|
void |
deleteOffset(org.springframework.integration.kafka.core.Partition partition)
Removes the offset for a given
Partition . |
void |
setAutoOffsetReset(SpringXdOffsetManager.AutoOffsetResetStrategy autoOffsetResetStrategy) |
close, flush, getConsumerId, getMetadataStore, getOffset, getReferenceTimestamp, resetOffsets, setConsumerId, setMetadataStore, setReferenceTimestamp, updateOffset
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
public SpringXdOffsetManager(org.springframework.integration.kafka.core.ConnectionFactory connectionFactory)
public SpringXdOffsetManager(org.springframework.integration.kafka.core.ConnectionFactory connectionFactory, java.lang.String topic, java.lang.String initialOffsets)
MetadataStoreOffsetManager
withconnectionFactory
- initialOffsets
- public void deleteOffset(org.springframework.integration.kafka.core.Partition partition)
DeletableOffsetManager
Partition
.deleteOffset
in interface DeletableOffsetManager
public void setAutoOffsetReset(SpringXdOffsetManager.AutoOffsetResetStrategy autoOffsetResetStrategy)