One server vs. multiple clients with data communication
I have a question on how to implement a server and multiple clients with data communication.
They share the same dataset for each step. That is, a s开发者_StackOverflow中文版erver gets the same step's data for each client. I have no idea how to sync all clients and communicate data file for each step.
Can you give me some hints or a basic idea? An example will be perfect.
Take a loot at these
Multi-threaded multi-client server in python
Client Server programming in python?
http://ilab.cs.byu.edu/python/select/echoserver.html
If you don't want to deal with details like socket and connection handling and you like high diving, you should look into Twisted
Here's a SO answer with a simple example of a server using Twisted
精彩评论