We had a legacy application built on IBM RAD tech stack which has Socket Server and client ( Client is a third party application)
Server was using BufferedReader and BufferedWriter to read and write data from sockets in IBM-1025 Char set.
Now i am re writing the same server in Java6
As part of application specific protocol....
After the successful connection client should send a time stamp in str format to start the communication.
Here ... the new server is failing to read the data and is on hold for some time @ read statement before Connection times out.
Here i used diff alternates to get this worked.
But could not able to succeed.
I'm assuming that you're using the method BufferedReader.readLine(). That method reads a line from the buffer. A line is terminated either by a line feed, carriage return or both. So if the client doesn't send a line terminator then the method will block and wait until one is send.
"Any fool can write code that a computer can understand. Good programmers write code that humans can understand." --- Martin Fowler
Please correct my English.