client server communication protocol
Posted on 2003-02-19
I'm implementing a java based inventory and order control system using a traditional 3 tier approach - client, server, database server. I am using java for both client and server along with mySql for the database side of things.
The question relates to how to communicate between the java client and server. Due to the nature of the system it has a rich set of requests and variety of data structures to be exchanged across the tcp connection. My initial thought was to encode this into an XML dtd and use appropriate xml parsers at each end to direct the requests and results to the appropriate sub handler and so on. However it looks like it could get quite messy with the inherent variety of message configurations possible.
Has anyone else had a similarly complex message structure to support using similar techniques? Or maybe there is an ability of Java I have overlooked (I prefer to use simple tcp socket based communication as opposed to the numerous messaging protocols for speed and processing overhead).
As this is a bit vague I'm not after a complete solution, just some pointers in the right direction will be fine!