import com.google.common.annotations.Beta;
import java.util.Optional;
+import org.opendaylight.controller.cluster.access.concepts.RequestException;
@Beta
public final class ConnectingClientConnection<T extends BackendInfo> extends AbstractClientConnection<T> {
// Initial state, never instantiated externally
ConnectingClientConnection(final ClientActorContext context, final Long cookie) {
- super(context, cookie, new TransmitQueue.Halted(TARGET_QUEUE_DEPTH));
+ super(context, cookie, TARGET_QUEUE_DEPTH);
}
@Override
}
@Override
- ClientActorBehavior<T> lockedReconnect(final ClientActorBehavior<T> current) {
- throw new UnsupportedOperationException("Attempted to reconnect a connecting connection");
+ long backendSilentTicks(final long now) {
+ // We are still connecting and do not want the timer to attempt a reconnect
+ return 0;
+ }
+
+ @Override
+ ClientActorBehavior<T> lockedReconnect(final ClientActorBehavior<T> current, final RequestException cause) {
+ throw new UnsupportedOperationException("Attempted to reconnect a connecting connection", cause);
}
}