How can the server code keep track of clients. I am unable to understand this: if a client A and client B are continuously sending request to the server, how will I know which one is client A and which one is client B ??
please help.
my server code is:-
while (true) {
try {
System.out.println("Connecting " + count++);
Socket client = acceptor.accept();
System.out.println("here 1");
logger.log(Level.INFO, "Client ["+client.getInetAddress() +"] tried to connect at "
+ new GregorianCalendar().getTime());
logger.log(Level.INFO,
"Connection received from " + client.getInetAddress()
+ ":" + client.getLocalPort() );
processRequest(client);
}