Reputation: 1119
Hi All I have a small question.
Now my Problem is in client I will be sending data continuously with out caring about acknowledgement example:
Suppose I am sending some 1000 messages from client. The client sends all the data in the socket.
If error occurs server will also put error message in the socket.
But either one can happen: send data from client or send message from the server.
What is the best way to handle the case?
If any error occurs and client receives the error message from the server then the client has to resend the data. One way is to send the data and wait for acknowledgement. I don't want client to wait for servers ack because chances of error are very less. Can any one tell me some good solution to this?
Upvotes: 0
Views: 367
Reputation: 25177
Have the error message include the 'index' the client should restart sending at.
Upvotes: 1