code: public void run()
     {
        while (running.get())
        {
           try
           {
              Socket socket = ss.accept();
  
              HandlerSocket hs = new HandlerSocket(handler, socket, this);
              active.add(hs);
              executorService.submit(hs);
           }
           catch (Exception e)
           {
              if (running.get())
                 e.printStackTrace(System.err);
           }
        }
     }
docs: Run