Download

Is there any size limits for TCP package?

Hi, community. Recently, I create a socket based on UDP to send binary data, however, sometimes the size of data will exceed 64k, emmm… It means the Tarray<uint8>'s num is bigger than 64 * 1024. Every time when I want to send it in one time, it will fail.
After searching the Internet, I found TCP may solve this problem. So, I want know if there is any size limits for TCP package in UE4. Can I use TCP socket to send a Tarray<uint8>, whose size is bigger than 64 * 1024, in one time?.

TCP is limited to 64K in one datagram, so you need to break it out into multiple chunks (not sure how you do that with an array - probably NetSerializer or some such) but I’m sure there’s some way).