My sincere apologies if this is a repeat post but the search limitations on < 4 char words makes it difficult. Also, forgive the length, I want to make sure I ask the question correctly the first time.
Anyway, my questions is this. I know a lot about networking as I've taken many cisco classes and have made several net apps. I know it is designed to be very reliable and efficient. It uses windows and confirmations to make sure every thing has been received.
However, I've heard many times from many resources that TCP isn't 100% guaranteed. Packets are not always received in order, are often strung together or are not received at all. Now that's only what I've heard. I've made a few networking apps back in VB6 using winsock and never had these problems, however, that was on a very stable connection and sending very small packages.
Now I want to move onto something a bit better. I'm trying to develop a low-level socket class that offers very efficient and near perfect transfers of data, no matter the size. I want to be sure that all packets are received if it's a file of several gigabytes, but also act very fast if there are many small packets coming from different connections.
To sum up all of that into a simple question. Should I take the time to implement a more guaranteed transfer using packet ids, lengths, crc, all of that (basically that's a whole different protocol!), or should I trust that tcp will get me all of the information? If the former is the case and to be sure i'd have to make my own custom protocol, couldn't i just use UDP and put that protocol over top of it?
I know there is probably no way to guarantee 100% of the time all data will make it perfectly, but > 95% is good to me.
Thanks
- Mark
Anyway, my questions is this. I know a lot about networking as I've taken many cisco classes and have made several net apps. I know it is designed to be very reliable and efficient. It uses windows and confirmations to make sure every thing has been received.
However, I've heard many times from many resources that TCP isn't 100% guaranteed. Packets are not always received in order, are often strung together or are not received at all. Now that's only what I've heard. I've made a few networking apps back in VB6 using winsock and never had these problems, however, that was on a very stable connection and sending very small packages.
Now I want to move onto something a bit better. I'm trying to develop a low-level socket class that offers very efficient and near perfect transfers of data, no matter the size. I want to be sure that all packets are received if it's a file of several gigabytes, but also act very fast if there are many small packets coming from different connections.
To sum up all of that into a simple question. Should I take the time to implement a more guaranteed transfer using packet ids, lengths, crc, all of that (basically that's a whole different protocol!), or should I trust that tcp will get me all of the information? If the former is the case and to be sure i'd have to make my own custom protocol, couldn't i just use UDP and put that protocol over top of it?
I know there is probably no way to guarantee 100% of the time all data will make it perfectly, but > 95% is good to me.
Thanks
- Mark