From: Claudio D. Gasparini Date: Thu, 1 Feb 2018 22:57:44 +0000 (+0100) Subject: Remove deprecated methods X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?a=commitdiff_plain;h=refs%2Fchanges%2F86%2F68786%2F2;p=bgpcep.git Remove deprecated methods Change-Id: I7abb75ae3b151e3ff3171b78fee47cb6853c2478 Signed-off-by: Claudio D. Gasparini --- diff --git a/bgp/rib-impl/src/main/java/org/opendaylight/protocol/bgp/rib/impl/BGPDispatcherImpl.java b/bgp/rib-impl/src/main/java/org/opendaylight/protocol/bgp/rib/impl/BGPDispatcherImpl.java index 61a9300559..a35bd0a023 100644 --- a/bgp/rib-impl/src/main/java/org/opendaylight/protocol/bgp/rib/impl/BGPDispatcherImpl.java +++ b/bgp/rib-impl/src/main/java/org/opendaylight/protocol/bgp/rib/impl/BGPDispatcherImpl.java @@ -76,14 +76,6 @@ public class BGPDispatcherImpl implements BGPDispatcher, AutoCloseable { this.handlerFactory = new BGPHandlerFactory(messageRegistry); } - @Override - public synchronized Future createClient( - final InetSocketAddress remoteAddress, - final int retryTimer) { - return createClient(remoteAddress, retryTimer, - createClientBootStrap(KeyMapping.getKeyMapping(), false)); - } - private synchronized Future createClient(final InetSocketAddress remoteAddress, final int retryTimer, final Bootstrap clientBootStrap) { final BGPClientSessionNegotiatorFactory snf = new BGPClientSessionNegotiatorFactory(this.bgpPeerRegistry); diff --git a/bgp/rib-impl/src/main/java/org/opendaylight/protocol/bgp/rib/impl/spi/BGPDispatcher.java b/bgp/rib-impl/src/main/java/org/opendaylight/protocol/bgp/rib/impl/spi/BGPDispatcher.java index f9a7b9a4f6..03713c5776 100755 --- a/bgp/rib-impl/src/main/java/org/opendaylight/protocol/bgp/rib/impl/spi/BGPDispatcher.java +++ b/bgp/rib-impl/src/main/java/org/opendaylight/protocol/bgp/rib/impl/spi/BGPDispatcher.java @@ -7,50 +7,21 @@ */ package org.opendaylight.protocol.bgp.rib.impl.spi; -import com.google.common.base.Optional; import io.netty.channel.ChannelFuture; import io.netty.util.concurrent.Future; import java.net.InetSocketAddress; -import org.opendaylight.protocol.bgp.rib.spi.BGPSession; import org.opendaylight.protocol.concepts.KeyMapping; /** * Dispatcher class for creating BGP clients. */ -public interface BGPDispatcher{ - - /** - * Creates BGP client. - * - * @param remoteAddress remote Peer address - * @param retryTimer Retry timer - * @return Future promising a client session - */ - @Deprecated - Future createClient(InetSocketAddress remoteAddress, int retryTimer); - +public interface BGPDispatcher { /** * Creates Reconnecting client. * * @param remoteAddress remote Peer Address - * @param retryTimer Retry timer - * @param keys for TCPMD5 - * @return Future promising a client session - */ - @Deprecated - default Future createReconnectingClient(InetSocketAddress remoteAddress, int retryTimer, Optional keys) { - if(keys.isPresent()) { - return createReconnectingClient(remoteAddress, retryTimer, keys.get()); - } - return createReconnectingClient(remoteAddress, retryTimer, KeyMapping.getKeyMapping()); - } - - /** - * Creates Reconnecting client. - * - * @param remoteAddress remote Peer Address - * @param retryTimer Retry timer - * @param keys for TCPMD5 + * @param retryTimer Retry timer + * @param keys for TCPMD5 * @return Future promising a client session */ Future createReconnectingClient(InetSocketAddress remoteAddress, int retryTimer, KeyMapping keys); @@ -59,13 +30,13 @@ public interface BGPDispatcher{ * Create new BGP server to accept incoming bgp connections (bound to provided socket localAddress). * * @param localAddress Peer localAddress - * * @return ChannelFuture promising a client session */ ChannelFuture createServer(InetSocketAddress localAddress); /** * Return BGP Peer Registry + * * @return BGPPeerRegistry */ BGPPeerRegistry getBGPPeerRegistry();