Class AbstractNetconfDispatcher<S extends org.opendaylight.netconf.api.NetconfSession,L extends org.opendaylight.netconf.api.NetconfSessionListener<? super S>>
- java.lang.Object
-
- org.opendaylight.netconf.nettyutil.AbstractNetconfDispatcher<S,L>
-
@Deprecated public abstract class AbstractNetconfDispatcher<S extends org.opendaylight.netconf.api.NetconfSession,L extends org.opendaylight.netconf.api.NetconfSessionListener<? super S>> extends Object
Deprecated.Dispatcher class for creating servers and clients. The idea is to first create servers and clients and the run the start method that will handle sockets in different thread.
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description protected static interfaceAbstractNetconfDispatcher.ChannelPipelineInitializer<C extends io.netty.channel.Channel,S extends org.opendaylight.netconf.api.NetconfSession>Deprecated.protected static interfaceAbstractNetconfDispatcher.PipelineInitializer<S extends org.opendaylight.netconf.api.NetconfSession>Deprecated.
-
Constructor Summary
Constructors Modifier Constructor Description protectedAbstractNetconfDispatcher(io.netty.channel.EventLoopGroup bossGroup, io.netty.channel.EventLoopGroup workerGroup)Deprecated.protectedAbstractNetconfDispatcher(io.netty.util.concurrent.EventExecutor executor, io.netty.channel.EventLoopGroup bossGroup, io.netty.channel.EventLoopGroup workerGroup)Deprecated.
-
Method Summary
All Methods Instance Methods Concrete Methods Deprecated Methods Modifier and Type Method Description protected io.netty.util.concurrent.Future<S>createClient(InetSocketAddress address, ReconnectStrategy strategy, io.netty.bootstrap.Bootstrap bootstrap, AbstractNetconfDispatcher.PipelineInitializer<S> initializer)Deprecated.Create a client but use a pre-configured bootstrap.protected io.netty.util.concurrent.Future<S>createClient(InetSocketAddress address, ReconnectStrategy strategy, AbstractNetconfDispatcher.PipelineInitializer<S> initializer)Deprecated.Creates a client.protected ReconnectFuturecreateReconnectingClient(InetSocketAddress address, ReconnectStrategyFactory connectStrategyFactory, AbstractNetconfDispatcher.PipelineInitializer<S> initializer)Deprecated.Creates a reconnecting client.protected io.netty.channel.ChannelFuturecreateServer(InetSocketAddress address, AbstractNetconfDispatcher.PipelineInitializer<S> initializer)Deprecated.Creates server.protected <C extends io.netty.channel.Channel>
io.netty.channel.ChannelFuturecreateServer(SocketAddress address, Class<? extends io.netty.channel.ServerChannel> channelClass, AbstractNetconfDispatcher.ChannelPipelineInitializer<C,S> initializer)Deprecated.Creates server.protected voidcustomizeBootstrap(io.netty.bootstrap.Bootstrap bootstrap)Deprecated.Customize a client bootstrap before the connection is attempted.protected voidcustomizeBootstrap(io.netty.bootstrap.ServerBootstrap bootstrap)Deprecated.Customize a server bootstrap before the server is created.
-
-
-
Constructor Detail
-
AbstractNetconfDispatcher
protected AbstractNetconfDispatcher(io.netty.channel.EventLoopGroup bossGroup, io.netty.channel.EventLoopGroup workerGroup)Deprecated.
-
AbstractNetconfDispatcher
protected AbstractNetconfDispatcher(io.netty.util.concurrent.EventExecutor executor, io.netty.channel.EventLoopGroup bossGroup, io.netty.channel.EventLoopGroup workerGroup)Deprecated.
-
-
Method Detail
-
createServer
protected io.netty.channel.ChannelFuture createServer(InetSocketAddress address, AbstractNetconfDispatcher.PipelineInitializer<S> initializer)
Deprecated.Creates server. Each server needs factories to pass their instances to client sessions.- Parameters:
address- address to which the server should be boundinitializer- instance of PipelineInitializer used to initialize the channel pipeline- Returns:
- ChannelFuture representing the binding process
-
createServer
protected <C extends io.netty.channel.Channel> io.netty.channel.ChannelFuture createServer(SocketAddress address, Class<? extends io.netty.channel.ServerChannel> channelClass, AbstractNetconfDispatcher.ChannelPipelineInitializer<C,S> initializer)
Deprecated.Creates server. Each server needs factories to pass their instances to client sessions.- Parameters:
address- address to which the server should be boundchannelClass- TheClasswhich is used to createChannelinstances from.initializer- instance of PipelineInitializer used to initialize the channel pipeline- Returns:
- ChannelFuture representing the binding process
-
customizeBootstrap
protected void customizeBootstrap(io.netty.bootstrap.ServerBootstrap bootstrap)
Deprecated.Customize a server bootstrap before the server is created. This allows subclasses to assign non-default server options before the server is created.- Parameters:
bootstrap- Server bootstrap
-
customizeBootstrap
protected void customizeBootstrap(io.netty.bootstrap.Bootstrap bootstrap)
Deprecated.Customize a client bootstrap before the connection is attempted. This allows subclasses to assign non-default options before the client is created.- Parameters:
bootstrap- Client bootstrap
-
createClient
protected io.netty.util.concurrent.Future<S> createClient(InetSocketAddress address, ReconnectStrategy strategy, AbstractNetconfDispatcher.PipelineInitializer<S> initializer)
Deprecated.Creates a client.- Parameters:
address- remote addressstrategy- Reconnection strategy to be used when initial connection fails- Returns:
- Future representing the connection process. Its result represents the combined success of TCP connection as well as session negotiation.
-
createClient
protected io.netty.util.concurrent.Future<S> createClient(InetSocketAddress address, ReconnectStrategy strategy, io.netty.bootstrap.Bootstrap bootstrap, AbstractNetconfDispatcher.PipelineInitializer<S> initializer)
Deprecated.Create a client but use a pre-configured bootstrap. This method however replaces the ChannelInitializer in the bootstrap. All other configuration is preserved.- Parameters:
address- remote address
-
createReconnectingClient
protected ReconnectFuture createReconnectingClient(InetSocketAddress address, ReconnectStrategyFactory connectStrategyFactory, AbstractNetconfDispatcher.PipelineInitializer<S> initializer)
Deprecated.Creates a reconnecting client.- Parameters:
address- remote addressconnectStrategyFactory- Factory for creating reconnection strategy for every reconnect attempt- Returns:
- Future representing the reconnection task. It will report completion based on reestablishStrategy, e.g. success is never reported, only failure when it runs out of reconnection attempts.
-
-