R
RedLars
What would be a good solution for the following scenario? I have one
server and multiple client application running on different computers
connected by Ethernet. Internal state changes in the server needs to
be communicated to the client and user operations performed on the
client need to be sent to the server. Sort of a peer-to-peer
communications model where each party can start a communication
session. A service would also be implemented on the server that pings
the clients every x seconds. Creating a new tcp socket connection for
each transaction would be slow. Creating one tcp socket connection
from server to client would only handle transaction started by the
server, right? Or can both parties send at any given time on one tcp
socket? What happens if they send at the same time? So I would have to
have two connections between a server and client, one for transactions
started by server and one for transactions started by the client.
However this would lead to having two sockets pr client, so if I had
40 clients that would be 80 sockets. Is this a concern? Using Udp
would also be an option but that requires some sort of acknowledgement
system. Thoughts?
server and multiple client application running on different computers
connected by Ethernet. Internal state changes in the server needs to
be communicated to the client and user operations performed on the
client need to be sent to the server. Sort of a peer-to-peer
communications model where each party can start a communication
session. A service would also be implemented on the server that pings
the clients every x seconds. Creating a new tcp socket connection for
each transaction would be slow. Creating one tcp socket connection
from server to client would only handle transaction started by the
server, right? Or can both parties send at any given time on one tcp
socket? What happens if they send at the same time? So I would have to
have two connections between a server and client, one for transactions
started by server and one for transactions started by the client.
However this would lead to having two sockets pr client, so if I had
40 clients that would be 80 sockets. Is this a concern? Using Udp
would also be an option but that requires some sort of acknowledgement
system. Thoughts?