Requires Free Membership to View
When you register, you'll begin receiving targeted emails from my team of award-winning writers. Our goal is to keep you informed on recent service-oriented architecture (SOA) and SOA-related topics such as integration, governance, Web services, Cloud and more.
Hannah Smalltree, Editorial DirectorMost Web servers have unique implementations of HTTP Tunneling and some have no support at all. This makes HTTP tunneling tricky at best. Further complications are added when attempting to move from one EJB Server to another. Proprietary extensions added by EJB vendors for many developers into supporting only one or two EJB providers. RMI, which is fairly beefy, with stub code downloading, distributed garbage collection, client-activation, RMI registry code, etc. is also starting to scare developers away. With these things in mind, many engineers are turning to a two-way, client-callback solution.
In a two-way, client callback solution, the client first attempts to establish a connection to the server using sockets. If the client can connect successfully to the server over an arbitrary socket connection, the server discovers the client's location and establishes a callback-socket connection in which to relay messages over. If firewall issues prevent the arbitrary socket connection from succeeding, then the client morphs into a client-side HTTP-server. At this point, the client and server can communicate over port 80 using HTTP requests/responses.
With the communication channel in place, the server acts as a front controller that dispatches requests to the appropriate business-logic modules (Java classes, Java Beans EJBs, SOAP provider, etc.). The server then receives the results from the business-logic modules, formats them for the client and passes them back to the client over the communication channel.
Using the data-format protocol is a decision that should be made based on
the needs of the client and the services provided by the server. XML data
formats such as SOAP are becoming more and more prevalent and generally
prove to be a safe bet for a generic implementation.
This was first published in April 2002