Musings about Coding, Business and other Geek Stuff Live and Direct from somewhere on the planet
August 29, 2002
SOAP programing paradigms

I haven't had time to finish the SOAP interface to my XML/X example app just yet as I've been travelling. However I have spent a lot of time reading and thinking about SOAP.

The big debate at the moment is wether SOAP should be used using an RPC based paradigm or a message based Paradigm. I think really it depends on what your particular need is.

However asynchronous messages are generally a lot more efficient for large scale distributed applications. Just look at Investment Banking where they have to deal with large amounts of real time feeds. The only way to do this is by using Message Bus'es and Message Queues.

I think people tend to go for the RPC based approach, because it's easier to code. If you take the Message based approach you really do need to rethink your application architecture. Which is exactly what I will do for the XML/X application.

While it's not exactly the same, a similar problem occurs when writing web applications. HTTP is a stateless protocol, so you need to simulate state in some way. App Server and Toolkit vendors invented Session objects to take care of this and make it easy for the developer to handle state. Now, I've never been a great fan of Session objects. Maybe it's because I've been doing CGI coding since 1994 and I just dont trust other peoples code. But really I think most bugs with web applications are because of misuse of Session Objects. The session objects were invented to make web programming more similar to traditional gui programming. (Artificial GUI Events such as in ASP.NET and NetDynamics are another)

There are many other ways of handling state in web based applications that are a lot more robust. They just take a slightly different approach to programming. I have always favored a Non Session based approach, where we dont care about what happened before, but only on the value of CGI variables.

A few interesting stories about this are:
RPC won't wash with SOAP and Beyond Encapsulation by Phil Wainewright.
The Correct Use of SOAP by Mark O'Neill
REST + SOAP by Sam Ruby

Posted by pelleb at August 29, 2002 04:38 AM
This entry was posted in the following Categories: Web Services
Comments
Post a comment
Name:


Email Address:


URL:


Comments:


Remember info?