@Override
    public void run() {
        
        try {
            ServerSocket serverSocket = new ServerSocket(super.port);
            NetworkTrafficLogger.getInstance().writeLogToTextArea("Start listening to TCP on Port: " + super.port);
            while (true) {
                try {
                    Socket socket = serverSocket.accept();
                    DataPacket packet = new DataPacket(socket.getInetAddress().getHostName(), socket.getPort(), new byte[DataPacket.DEFAULT_DATA_SIZE]);
                    InputStream input = socket.getInputStream();
                    input.read(packet.getData());
                    input.close();
                    super.message_queue.put(packet);
                    NetworkTrafficLogger.getInstance().writeReceiveLogToTextArea(packet);
                } catch (InterruptedException ex) {
                    Logger.getLogger(TCPNetworkServerImpl.class.getName()).log(Level.SEVERE, null, ex);
                }
            }
        } catch (IOException ex) {
            Logger.getLogger(TCPNetworkServerImpl.class.getName()).log(Level.SEVERE, null, ex);
        }
    }