Search in sources :

Example 1 with RetryTracker

use of com.hazelcast.jet.retry.impl.RetryTracker in project hazelcast by hazelcast.

the class CdcSourceP method init.

@Override
protected void init(@Nonnull Context context) {
    // workaround for https://github.com/hazelcast/hazelcast-jet/issues/2603
    DriverManager.getDrivers();
    String name = getName(properties);
    this.logger = context.logger();
    RetryStrategy retryStrategy = getRetryStrategy(properties);
    log(logger, name, "retry strategy", retryStrategy);
    this.reconnectTracker = new RetryTracker(retryStrategy);
    snapshotting = !NONE.equals(context.processingGuarantee());
    if (!snapshotting) {
        this.commitPeriod = getCommitPeriod(properties);
        log(logger, name, "commit period", commitPeriod);
        if (commitPeriod > 0) {
            lastCommitTime = System.nanoTime();
        }
    }
    this.clearStateOnReconnect = getClearStateOnReconnect(properties);
    log(logger, name, "clear state on reconnect", clearStateOnReconnect);
}
Also used : RetryTracker(com.hazelcast.jet.retry.impl.RetryTracker) RetryStrategy(com.hazelcast.jet.retry.RetryStrategy)

Aggregations

RetryStrategy (com.hazelcast.jet.retry.RetryStrategy)1 RetryTracker (com.hazelcast.jet.retry.impl.RetryTracker)1