Both :-) The host uses the server_send values to determine how much
and how often it can send data to each client. The host uses the
client_send values to determine how much and how often it should expect
to see data from each client. (Note that the sizes are maximums -
frequently it won't be necessary to send that much data, so smaller
packets will be sent (ever notice that your modem lights glow brighter
while in a race with several cars than when selecting parameters for
the race?))
Similarly, the client uses the client_send values to determine how
much/often it can send to the server, and the server_send values to
determine how much/often it can expect to see from the server.
It's critical that the client_send_size on the client be no greater
than the client_send_size on the host. If this is not the case, the
client may send a packet to the host that is larger than the host
believes is possible, and this will cause the host to disconnect the
client. Similarly, it is critical that the server_send_size on the
host be no larger than the server_send_size on the client. Otherwise
the client may see a packet from the server that is larger than it
believes is possible, and disconnect from the server.
It's best to have the send_every's match, but it's not critical. A GPL
host will disconnect a client if it receives less than 50% of the
number of packets it expects to see from that client (that'd be a
pretty crappy connection). But, if the client had a client_send_every
of 3, and the server had a client_send_every of 2, then with a perfect
connection the server would only be seeing 67% of what it was expecting
to see from the client. This doesn't leave much margin for packet loss
before the server dumps the client. (This also works in reverse - if a
client isn't getting 50% of the number of packets it expects to see
from the server, it will disconnect from the server).
While the cable/ADSL/T1 line may have enough upload bandwidth to allow
the server to send a 340 byte packet to each of several clients, if the
clients are only connected to the Internet with 28.8 modems, they won't
have the download bandwidth to accept it
340bytes/packet*10bits/byte*36cycles/second*0.333packets/cycle=40800bits
/sec
before accounting for IP overhead (which is significant).
Randy