I am building both an engine and a networked game at once because I'm completely insane. The original design/plan was to use internal Unix sockets for each "zone" for server<->zone communication, with UDP for server<->client(s) communication.
My conundrum is this: It seems like there are a variety of ways to handle getting packets from a client to the intended "zone", not none of them seem particularly efficient.
- Simply move data from a singular queue to the intended zone server, via data objects within code. (Pro: Simple // Con: Potentially slow as molasses in a Canadian winter.)
- (Somehow) Allow Server and Zones to communicate via Unix sockets, with a networking class/wrapper to pass packets into a "pool" for redistribution to Zones. (Pro: Unix sockets, from my reading, tend to be fairly quick. // Con: Need to re-evaluate how I am currently handling packets and the redistribution of packets makes it too similar to #1 for my liking.)
- Use the underlying messages system on Linux. Ref (Pro: Crazy fast for large objects. // Con: No idea how to implement at the moment.)
Additionally, if there is a specific text, document, or book(s) that I should be hitting instead of harassing everyone here, PLEASE let me know! Not at all afraid to spend a week tearing through a 200+ page tome.