X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?p=controller.git;a=blobdiff_plain;f=opendaylight%2Fnetconf%2Fnetconf-client%2Fsrc%2Fmain%2Fjava%2Forg%2Fopendaylight%2Fcontroller%2Fnetconf%2Fclient%2FNetconfClient.java;h=d644cddff4855afe0a6e87b399a81d9eb5f5b152;hp=61a9a9b9548bc6eeb771dcf952c61e08e4a669f3;hb=28ef055f38762a2f9679eb765fa44528b56791a8;hpb=b0e337733be06807c12d5bbd3b5a29a94f44fdba diff --git a/opendaylight/netconf/netconf-client/src/main/java/org/opendaylight/controller/netconf/client/NetconfClient.java b/opendaylight/netconf/netconf-client/src/main/java/org/opendaylight/controller/netconf/client/NetconfClient.java index 61a9a9b954..d644cddff4 100644 --- a/opendaylight/netconf/netconf-client/src/main/java/org/opendaylight/controller/netconf/client/NetconfClient.java +++ b/opendaylight/netconf/netconf-client/src/main/java/org/opendaylight/controller/netconf/client/NetconfClient.java @@ -50,7 +50,6 @@ public class NetconfClient implements Closeable { private NetconfClient(String clientLabelForLogging, InetSocketAddress address, ReconnectStrategy strat, NetconfClientDispatcher netconfClientDispatcher) throws InterruptedException { this.label = clientLabelForLogging; dispatch = netconfClientDispatcher; - sessionListener = new NetconfClientSessionListener(); Future clientFuture = dispatch.createClient(address, sessionListener, strat); this.address = address; @@ -101,6 +100,10 @@ public class NetconfClient implements Closeable { clientSession.close(); } + public NetconfClientDispatcher getNetconfClientDispatcher() { + return dispatch; + } + private static ReconnectStrategy getReconnectStrategy(int connectionAttempts, int attemptMsTimeout) { return new TimedReconnectStrategy(GlobalEventExecutor.INSTANCE, attemptMsTimeout, 1000, 1.0, null, Long.valueOf(connectionAttempts), null);