code: synchronized void closeSocket() {
  
          @Nullable SocketChannel clientChannel = this.clientChannel;
  
          if (clientChannel != null) {
  
              try {
                  clientChannel.socket().shutdownInput();
              } catch (ClosedChannelException ignored) {
  
              } catch (IOException e) {
                  Jvm.debug().on(getClass(), e);
              }
  
              try {
                  clientChannel.socket().shutdownOutput();
              } catch (ClosedChannelException ignored) {
  
              } catch (IOException e) {
                  Jvm.debug().on(getClass(), e);
              }
  
              Closeable.closeQuietly(clientChannel);
  
              this.clientChannel = null;
  
              if (LOG.isDebugEnabled())
                  Jvm.debug().on(getClass(), "closing", new StackTrace("only added for logging - please ignore !"));
  
              @NotNull final TcpSocketConsumer tcpSocketConsumer = this.tcpSocketConsumer;
  
              tcpSocketConsumer.tid = 0;
              tcpSocketConsumer.omap.clear();
  
              onDisconnected();
  
          }
      }
docs: closes the existing connections