Skip to content

Using Reed-Solomon codes to transfer data between the client - server #288

Answered by klauspost
LazarenkoA asked this question in Q&A
Discussion options

You must be logged in to vote

Applying the correct RS to transport is tricky. If you have unreliable transport I assume you are using something like UDP.

I have seen approaches where each UDP package is encoded as a shard, with say 40000 data packets and 20000 RS packets are sent in groups. Exact numbers are not important, but total below 65536. Since the UDP packets are fairly small, that can be done with a single Encode/Decode. Each packet then also contains the index and a checksum (xxhash3 for example).

If you are worried about long-stretch errors, you can use EncodeIdx on say 16 groups and send one or two parity shards in case you lose more than 20K UDP blocks in a group.

Doing long shard encodes can also be done…

Replies: 1 comment

Comment options

You must be logged in to vote
0 replies
Answer selected by klauspost
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants
Converted from issue

This discussion was converted from issue #287 on September 09, 2024 08:43.