public class ChangelogSSPIterator
extends java.lang.Object
SystemStreamPartition using the provided
SystemConsumer until all messages have been consumed.
The iterator has a ChangelogSSPIterator.Mode that depends on its position in the changelog SSP. If trim mode
is enabled, the mode switches to TRIM if the current message offset is greater than the
provided endOffset, or if endOffset is null.
The iterator mode is used during transactional state restore to determine which changelog SSP entries
should be restored and which ones need to be reverted / trimmed from the changelog topic.| Modifier and Type | Class and Description |
|---|---|
static class |
ChangelogSSPIterator.Mode |
| Constructor and Description |
|---|
ChangelogSSPIterator(SystemConsumer systemConsumer,
SystemStreamPartition systemStreamPartition,
java.lang.String endOffset,
SystemAdmin admin,
boolean trimEnabled) |
| Modifier and Type | Method and Description |
|---|---|
ChangelogSSPIterator.Mode |
getMode() |
boolean |
hasNext() |
IncomingMessageEnvelope |
next() |
public ChangelogSSPIterator(SystemConsumer systemConsumer, SystemStreamPartition systemStreamPartition, java.lang.String endOffset, SystemAdmin admin, boolean trimEnabled)
public boolean hasNext()
public IncomingMessageEnvelope next()
public ChangelogSSPIterator.Mode getMode()