Convert netconf-util, netconf-ssh, netconf-tcp to blueprint
[netconf.git] / netconf / netconf-ssh / src / test / java / org / opendaylight / netconf / netty / ProxyServer.java
index ee34f8fd2f1ad2acbf4a746f1794bc140513563d..b465e381f2be3d862a59ba9dd1ce6353065205a0 100644 (file)
@@ -21,7 +21,7 @@ import io.netty.channel.socket.nio.NioServerSocketChannel;
 import io.netty.handler.logging.LogLevel;
 import io.netty.handler.logging.LoggingHandler;
 import java.net.InetSocketAddress;
-import org.opendaylight.netconf.util.osgi.NetconfConfiguration;
+import org.opendaylight.netconf.util.NetconfConfiguration;
 
 public class ProxyServer implements Runnable {
     private final ProxyHandlerFactory proxyHandlerFactory;
@@ -30,6 +30,7 @@ public class ProxyServer implements Runnable {
         this.proxyHandlerFactory = proxyHandlerFactory;
     }
 
+    @SuppressWarnings("checkstyle:IllegalCatch")
     public void run() {
         // Configure the server.
         final EventLoopGroup bossGroup = new NioEventLoopGroup();
@@ -50,10 +51,10 @@ public class ProxyServer implements Runnable {
 
             // Start the server.
             InetSocketAddress address = new InetSocketAddress("127.0.0.1", 8080);
-            ChannelFuture f = serverBootstrap.bind(address).sync();
+            ChannelFuture future = serverBootstrap.bind(address).sync();
 
             // Wait until the server socket is closed.
-            f.channel().closeFuture().sync();
+            future.channel().closeFuture().sync();
         } catch (Exception e) {
             throw new RuntimeException(e);
         } finally {
@@ -62,7 +63,8 @@ public class ProxyServer implements Runnable {
             workerGroup.shutdownGracefully();
         }
     }
-    public static interface ProxyHandlerFactory {
+
+    public interface ProxyHandlerFactory {
         ChannelHandler create(EventLoopGroup bossGroup, LocalAddress localAddress);
     }