title: Spring Integration TCP force reconnect from both sides
body: <p>I recently received an answer on how I could force a reconnect from the client side (Client mode TCP connection factory and adapters).</p>
  
  <p>But I also need to be able to close a connection from the server side (Server TCP connection factory and non-client-mode adapters).</p>
  
  <p>I need to support a situation where, if some custom correlation logic goes out of sync, the connection is closed, and both sides react to this by resetting their counters etc.</p>
  
  <p>So I need to:</p>
  
  <ol>
  <li>Force a TCP disconnect from server </li>
  <li>Force a TCP reconnect from client </li>
  <li>Have the server code discover that the connection was
  closed from the client (is there an event or such?) </li>
  <li>Have the client code discover that the connection was closed from the server
  (event?)</li>
  </ol>