I am writing a network application that has several machines that serve separate clients, but machine themselves need to communicate with each other frequently. Let's say multiple chat servers for example. How do I accomplish the server to server communication in terms of network architecture. I don't want each server to have a connection open with all other servers. Any ideas, pointers or suggestions would help. As a client developer, I am brand new to any of these. Thank you!
|
Why don't you want each server to have a connection open with all other servers? You could always install 2 NICs in each server. One NIC would serve clients and the other NIC would be used for server-to-server communication. Another option would be to create VLANs but I still don't understand why don't you want each server to have a connection open with all other servers? |
|||||
|
|
If the communication does not need to be instantaneous you could just use a central database server to store the messages (or whatever is being communicated) and then the other servers can pick them up when they are ready. An alternative would be to use a central server to act as an exchange, basically sitting waiting for messages then forwarding them to daemons on other servers as required. Doing it this way would be a lot more complex than the db option tho' as you would have to have methods in place to ensure that messages are actually passed on and some sort of retry mechanism for when they cannot be forwarded. |
|||
|
|