I write a simple mina client side
// this code start the client, doesn't close the client,because it must
received all the server data
public void start() {
  NioSocketConnector connector = new NioSocketConnector();
  sessionConfigSet(connector.getSessionConfig()); // 配置session config
  DefaultIoFilterChainBuilder chain = connector.getFilterChain();
  chain.addLast("codec", getProtocolCodecFilter());
  connector.setHandler(getHandler());
  ConnectFuture future = connector.connect(new InetSocketAddress(ip, port));
  future.awaitUninterruptibly();
 }
but if the server restart, the client can not received any data, how can I
fixed this situation?

Reply via email to