While working on Gate's code, I found an interesting thing.
The whole client-server communication is centralized on the "server" side, which implements… The server itself, of course, but also a "proxy" that is able to talk with it.
Great! It means that extracting the communication protocol itself will only involve changes in the server package. No shotgun surgery in the whole project.
The currently implemented protocol is go's RPC client, which works via HTTP. Not a bad choice; but I really would like to propose at least one alternate implementation, using ZMQ.
So the first thing is: move the current implementation out of the server implementation (which should concentrate on just implementing server stuff, not protocol), and out of its proxy implementation.
Well… the role of the proxy is only to send things to the server; but I like the symmetry, similar to ISO's stack: one layer talks to its counterpart at the same level. Hence, the server talks with its proxy, and each one should contain a "channel" object; each channel object should be able to talk to another channel object.
No comments:
Post a Comment
Note: Only a member of this blog may post a comment.