+ private void configureClient(final BGPExtensionProviderContext ctx) {
+ final InetSocketAddress clientAddress = new InetSocketAddress("127.0.11.0", 1791);
+ final IpAddress clientPeerIp = new IpAddress(new Ipv4Address(clientAddress.getAddress().getHostAddress()));
+ this.registry.addPeer(clientPeerIp, this.clientListener, createPreferences(clientAddress));
+ this.clientDispatcher = new TestClientDispatcher(new NioEventLoopGroup(), new NioEventLoopGroup(), ctx.getMessageRegistry(), clientAddress);
+ }
+
+ private Channel createServer(final InetSocketAddress serverAddress) throws InterruptedException {
+ this.serverListener = new SimpleSessionListener();
+ this.registry.addPeer(new IpAddress(new Ipv4Address(serverAddress.getAddress().getHostAddress())), this.serverListener, createPreferences(serverAddress));
+ final ChannelFuture future = this.serverDispatcher.createServer(this.registry, serverAddress);