### Question:
NettyClient implements Closeable { public <T extends Command, C extends CommandCallback<T>> void send(final String addr, final T command, final C callback) { try { getConn(addr).request(command, callback); } catch (Exception ex) { if (callback != null) { callback.onFailed(command, ex); } else { throw ex; } } } NettyClient(final NettyClientConfig config, final Supplier<? extends Command> commandSupplier,
                     final Supplier<? extends ByteToMessageDecoder> decoderSupplier, final HeartbeatCommand heartbeat); boolean addListener(final EventListener listener); boolean removeListener(final EventListener listener); void publish(final Event e); void send(final String addr, final T command, final C callback); @Override void close();  }### Answer:
@Test public void sendTest() { int len = 1000; NettyClient nettyClient = new NettyClient(getNettyClientConfig(HEARTBEATINTERVAL * 30), TBaseCommand::new, () -> { return new LineBasedFrameDecoder(len); }, new THeartbeatCommand()); for (int i = 0; i < 10; i++) { TBaseCommand request = new TBaseCommand((short) 1, (long) i, i + "---i am ct. hello server.\n"); nettyClient.send(ADDRESS, request, new TCallback()); } sleep(5000); }