public static class OffsetCommitPolicy.PeriodicCommitOffsetPolicy extends Object implements OffsetCommitPolicy
OffsetCommitPolicy that will commit offsets no more than the specified time period. If the specified
time is less than 0 then the policy will behave as OffsetCommitPolicy.AlwaysCommitOffsetPolicy.io.debezium.engine.DebeziumEngine.OFFSET_FLUSH_INTERVAL_MSOffsetCommitPolicy.AlwaysCommitOffsetPolicy, OffsetCommitPolicy.PeriodicCommitOffsetPolicy| Modifier and Type | Field and Description |
|---|---|
private Duration |
minimumTime |
| Constructor and Description |
|---|
PeriodicCommitOffsetPolicy(Properties config) |
| Modifier and Type | Method and Description |
|---|---|
boolean |
performCommit(long numberOfMessagesSinceLastCommit,
Duration timeSinceLastCommit)
Determine if a commit of the offsets should be performed.
|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitalways, and, or, periodicprivate final Duration minimumTime
public PeriodicCommitOffsetPolicy(Properties config)
public boolean performCommit(long numberOfMessagesSinceLastCommit,
Duration timeSinceLastCommit)
OffsetCommitPolicyperformCommit in interface OffsetCommitPolicynumberOfMessagesSinceLastCommit - the number of messages that have been received from the connector since last
the offsets were last committed; never negativetimeSinceLastCommit - the time that has elapsed since the offsets were last committed; never negativetrue if the offsets should be committed, or false otherwiseCopyright © 2021 JBoss by Red Hat. All rights reserved.