Note that there are some explanatory texts on larger screens.

plurals
  1. POwhat is the right network protocol to use to transfer an integer number sporadically from computer A to B with lowest possible latency?
    primarykey
    data
    text
    <p>I'm not a network expert so please bear with me. I need to establish a very simple one-directional data connection between two computers, which will be used ~ every 100ms to transfer an integer number (int8 or int16), from computer A to computer B. The connection and data transfer will always be in the direction A -> B. Since I want to react as quickly as possible to packages coming in @ B, I'd like to know which protocol I should use in order to minimize network latencies. That is, I want the transfer to be as 'realtime' as possible, ideally with latencies being &lt; 10ms (and no packages should get lost if possible).</p> <p><strong>So here are my specific questions:</strong></p> <ol> <li>what communication protocols are suited for this job?</li> <li>is this latency that I'm trying to achieve realistic? </li> <li>what is the minimum latency that I could theoretically achieve?</li> <li>will the latency depend drastically on the switch used? Or will any cheap consumer switch do fine?</li> <li>in case I need to suddenly send more data, what are the optimal package sizes in order to minimize overhead?</li> <li>what's the best / correct way to actually measure latency? </li> <li>how much will the latency depend on the programming language used? (I'm considering java, c, python)</li> <li>what would the pros and cons be for using TCP?</li> <li>what would the pros and cons be for using UDP?</li> <li>what would the pros and cons be for using websockets?</li> </ol> <p>Computers A and B are connected to the same switch and are physically very close by and in order to reduce unnecessary 'network noise', the computers could be separated from the rest of the network. </p> <p>Sample code is greatly appreciated :)</p>
    singulars
    1. This table or related slice is empty.
    plurals
    1. This table or related slice is empty.
    1. This table or related slice is empty.
    1. This table or related slice is empty.
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload