<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/css" href="/stylesheets/rss.css"?>
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:trackback="http://madskills.com/public/xml/rss/module/trackback/">
  <channel>
    <title>Nimble Code: Tag soap</title>
    <link>http://www.nimblecode.com/articles/tag?tag=soap</link>
    <language>en-us</language>
    <ttl>40</ttl>
    <description>Jacob Harris' Weblog</description>
    <item>
      <title>The Silliness of SOA</title>
      <description>&lt;p&gt;There seems to be a lot of buzz around the concept of Service-Oriented Architecture (SOA), as long as you don&amp;#8217;t ask any of its proponents what it actually means. For an example of the ways in which English can be mangled by technical jargon beyond recognition, check out some of the definitions from &lt;a href="http://searchwebservices.techtarget.com/originalContent/0,289142,sid26_gci1017004,00.html"&gt;A Defining Moment for &lt;span class="caps"&gt;SOA&lt;/span&gt;&lt;/a&gt; and &lt;a href="http://searchwebservices.techtarget.com/originalContent/0,289142,sid26_gci1044083,00.html"&gt;Revisiting the Definitive &lt;span class="caps"&gt;SOA &lt;/span&gt;Definition&lt;/a&gt; to see what I mean. My personal favorite from the bunch is&lt;/p&gt;


	&lt;blockquote&gt;
		&lt;p&gt;SOA is a form of technology architecture that adheres to the principles of service orientation. When realized through the Web services technology platform, &lt;span class="caps"&gt;SOA&lt;/span&gt; establishes the potential to support and promote these principles throughout the business process and automation domains of an enterprise.&lt;/p&gt;
	&lt;/blockquote&gt;


	&lt;p&gt;which really tells me nothing at all about why this is cool and where you would start if your &lt;span class="caps"&gt;CEO&lt;/span&gt; suddenly decided you needed it. Cutting through the bombast and hype, it seems like &lt;span class="caps"&gt;SOA&lt;/span&gt; is basically&lt;/p&gt;


	&lt;blockquote&gt;
		&lt;p&gt;Wrapping a backend database or similar resource in a small component for business logic you can talk to with &lt;span class="caps"&gt;XML&lt;/span&gt;.&lt;/p&gt;
	&lt;/blockquote&gt;


	&lt;p&gt;This is definitely cool for many reasons (loose coupling, security, building big things from small parts), but I don&amp;#8217;t understand why there&amp;#8217;s so much hype about it now. Not to boast, but we&amp;#8217;ve been doing this at &lt;a href="http://www.alacra.com"&gt;Alacra&lt;/a&gt; for &lt;strong&gt;8 years&lt;/strong&gt; now, and I&amp;#8217;m really gobsmacked that this sort of architecture would be a revelation to anyone, especially since it builds on design patterns good sense and the older Unix and later Internet philosophy that &lt;a href="http://www.smallpieces.com/"&gt;Small Pieces Loosely Joined&lt;/a&gt; can make great things. And &lt;span class="caps"&gt;SOA&lt;/span&gt; is pretty much what the earliest &lt;span class="caps"&gt;XML&lt;/span&gt;-driven web services were.&lt;/p&gt;


	&lt;p&gt;I can only assume that the latest hype about &lt;span class="caps"&gt;SOA&lt;/span&gt; is less about what the technology is, but what it is not. Hint: add a P and you can see what businesses find so refreshing about &lt;span class="caps"&gt;SOA&lt;/span&gt;. SOAP is a heavyweight protocol that can be good for some external APIs, but is a lot more work than a simple quick and dirty internal application often needs. Imagine being able to drop the requirements of &lt;span class="caps"&gt;WSDL&lt;/span&gt; bindings, &lt;span class="caps"&gt;XML&lt;/span&gt; typing, even limited data structures to get the most lightweight, low-ceremony solutions you can feel comfortable with using. And since it&amp;#8217;s internal, you don&amp;#8217;t have to worry about the &amp;#8220;shame&amp;#8221; of not being fully &lt;span class="caps"&gt;SOAP&lt;/span&gt;+WS-whatever compliant for your &lt;span class="caps"&gt;API&lt;/span&gt;. Looking at it this way, no wonder they&amp;#8217;re excited. I&amp;#8217;d be excited too if I were able to stop documenting and start hacking for change.&lt;/p&gt;</description>
      <pubDate>Thu, 10 Nov 2005 09:06:00 -0800</pubDate>
      <guid isPermaLink="false">urn:uuid:e28be0e8-8e39-44fd-8427-1e243441332d</guid>
      <author>harrisj@nimblecode.com (Jacob Harris)</author>
      <link>http://www.nimblecode.com/articles/2005/11/10/the-silliness-of-soa</link>
      <category>Web Services</category>
      <category>soa</category>
      <category>soap</category>
      <category>xml</category>
      <category>alacra</category>
      <trackback:ping>http://www.nimblecode.com/articles/trackback/52</trackback:ping>
    </item>
    <item>
      <title>Extracted Standards</title>
      <description>Still busy, but there is a great article at O'Reilly Radar on how great frameworks are sometimes extracted wholesale from successful applications rather than built from scratch up. That is, it's &lt;a href="http://radar.oreilly.com/archives/2005/04/designing_from.html"&gt;often better to extract the framework from the application&lt;/a&gt;, rather than build the application on top of a framework:

&lt;blockquote&gt;That is, at 37signals, they try to design the usability and function of the application first, and that drives the implementation. And if they can then extract a re-usable framework, all the better. For example, basecamp wasn't built on top of Ruby on Rails. Rather, Ruby on Rails was extracted from basecamp.&lt;/blockquote&gt;

This echoes some of the complaints I was making earlier about the &lt;a href="/blog/?p=22"&gt;unwieldiness of SOAP&lt;/a&gt; for web standards. And it fits in with the philosophy of nimble technologies perfectly. Create a product, solve a need, and make it work great and the frameworks will follow, but complicated frameworks in themselves solve nothing.</description>
      <pubDate>Mon, 02 May 2005 21:39:00 -0700</pubDate>
      <guid isPermaLink="false">urn:uuid:420a4ac5f2837123fab29a7accd3d585</guid>
      <author>harrisj</author>
      <link>http://www.nimblecode.com/articles/2005/05/02/extracted-standards</link>
      <category>Web Coding</category>
      <category>rails</category>
      <category>ruby</category>
      <category>soap</category>
      <trackback:ping>http://www.nimblecode.com/articles/trackback/23</trackback:ping>
    </item>
    <item>
      <title>The New Web Math, Or How SOAP Adds Up To Nothing</title>
      <description>Last week saw the intriguing web mashups of combining two popular web services in one place. So, first there was &lt;a href="http://www.paulrademacher.com/housing/"&gt;combining Craigslist Real Estate listings with Google Maps&lt;/a&gt;, which although slow is really quite amazing to behold. Then someone else hacked &lt;a href="http://llimllib.f2o.org/blog/serve/entry/delbackup"&gt;Gmail + Del.icio.us&lt;/a&gt;, using Google's mail service to capture contents on bookmarked pages at the bookmarking time. Not to mention &lt;a href="http://www.holovaty.com/blog/archive/2005/04/19/0216"&gt;Adrian's trailblazing mix of Google Maps and Chicago transit info&lt;/a&gt;.

&lt;p&gt;All of these are amusing and technically well-executed hacks, but what is most amazing to me is not the front-end combinations, but the ease in which it is possible to mix web tools in the back end to create new powerful services. And I have been especially struck by how SOAP has been utterly unnecessary for this to happen. In fact, I would argue that the strict COM-style model of SOAP is exactly the problem here, in that SOAP requires such effort and planning, it resists such freeform discovery of capabilities beyond what the creators of products imagine. REST seems to have a natural advantage here in that it builds on the inherent procedural model of HTTP and thus can evolve as naturally as websites do. Combine that with dynamic HTML tricks and we can see how nimble code can outmaneuver the heavyweight mechanics of SOAP again and again.

&lt;p&gt;For a more lengthy and detailed critique of SOAP, see my earlier post, &lt;a href="/blog/?p=17"&gt;Radical Simplification&lt;/a&gt;</description>
      <pubDate>Mon, 25 Apr 2005 00:06:00 -0700</pubDate>
      <guid isPermaLink="false">urn:uuid:0fd93f5836f86ffbb25fc29b7709d57b</guid>
      <author>harrisj</author>
      <link>http://www.nimblecode.com/articles/2005/04/25/the-new-web-math-or-how-soap-adds-up-to-nothing</link>
      <category>Web Services</category>
      <category>soap</category>
      <category>craigslist</category>
      <category>google</category>
      <category>gmail</category>
      <category>rest</category>
      <trackback:ping>http://www.nimblecode.com/articles/trackback/21</trackback:ping>
    </item>
    <item>
      <title>Radical Simplification</title>
      <description>&lt;p&gt;David Heinemeier Hansson has posted an interested find over at his blog &lt;a href="http://www.loudthinking.com/"&gt;Loud Thinking&lt;/a&gt; about &lt;span class="caps"&gt;IBM&lt;/span&gt;&amp;#8217;s stated new goal to pursue &lt;a href="http://www.loudthinking.com/arc/000439.html"&gt;Radical Simplification&lt;/a&gt; in their enterprise work. Essentially, Big Blue is starting to acknowledge that most enterprise web development is just too cumbersome and daunting for agile and powerful web development. Things like &lt;span class="caps"&gt;SOAP&lt;/span&gt; and &lt;span class="caps"&gt;WSDL&lt;/span&gt; are examples of this. What should be a simple task like &lt;em&gt;retrieve a weather forecast from a remote site&lt;/em&gt; becomes a complicated mess of debugging &lt;span class="caps"&gt;SOAP&lt;/span&gt; calls, tweaking &lt;span class="caps"&gt;WSDL&lt;/span&gt; specifications and using wizards on the server to generate code that is impossible for the end user to debug, let alone understand.&lt;/p&gt;


	&lt;p&gt;Or as Sam Ruby puts in his excellent presentation to &lt;span class="caps"&gt;IBM&lt;/span&gt; on the topic &lt;a href="http://intertwingly.net/slides/2005/rs/"&gt;Hello From The Open Source World&lt;/a&gt;:&lt;/p&gt;


	&lt;blockquote&gt;
		&lt;p&gt;For normal people, the perceived usefulness of a computer language is inversely proportional to the amount of theory the language forces you to learn.&lt;/p&gt;
	&lt;/blockquote&gt;


	&lt;p&gt;Sam illustrates this in his slides by showing the classic &amp;#8220;Hello World&amp;#8221; example in a variety of programming languages on different slides. But when he reaches &lt;span class="caps"&gt;WSDL&lt;/span&gt; to specify it, it&amp;#8217;s a blank. Because, quite frankly, &lt;span class="caps"&gt;WSDL&lt;/span&gt; is so unwieldy to use, it&amp;#8217;s hard to just build it on the fly, forcing many people to plunk down bucks to Microsoft or &lt;span class="caps"&gt;IBM&lt;/span&gt; to get their compilers to build it for them. It&amp;#8217;s good business for those companies, but bad news for the Internet as a whole I think.&lt;/p&gt;


	&lt;p&gt;Ruby says that essentially for a framework to succeed on the web, it has to enable a situation he terms &lt;strong&gt;Zero Training&lt;/strong&gt;, a state where it is easy to get going in the language and to adapt examples to your own needs. Good programming languages have it, some web technologies have it, &lt;span class="caps"&gt;SOAP&lt;/span&gt; and &lt;span class="caps"&gt;WSDL&lt;/span&gt; don&amp;#8217;t. Indeed, I feel like the growth of &lt;span class="caps"&gt;SOAP&lt;/span&gt;/WSDL in the enterprise has been in spite of the difficulties of developing for it (mainly because of Microsoft and &lt;span class="caps"&gt;IBM&lt;/span&gt; pushing it). Because, quite frankly, it&amp;#8217;s a beast for anything but the most basic &lt;span class="caps"&gt;RPC&lt;/span&gt;-style calls. The reasons:&lt;/p&gt;


	&lt;ol&gt;
	&lt;li&gt;&lt;span class="caps"&gt;SOAP&lt;/span&gt; allows you to abstract away the underlying transport protocol. But for 99% of &lt;span class="caps"&gt;SOAP&lt;/span&gt; communication, this protocol is &lt;span class="caps"&gt;HTTP&lt;/span&gt;, and the abstraction limits the control you have over &lt;span class="caps"&gt;HTTP&lt;/span&gt;.&lt;/li&gt;
		&lt;li&gt;&lt;span class="caps"&gt;SOAP&lt;/span&gt; needs to validate the entire message before applications can operate on it. This usually means it has to load it up into a &lt;span class="caps"&gt;DOM&lt;/span&gt; as well, so calls that return lots of data or might take a while (&lt;em&gt;the fun ones&lt;/em&gt;) are frowned upon&lt;/li&gt;
		&lt;li&gt;&lt;span class="caps"&gt;SOAP&lt;/span&gt; also assumes the &lt;span class="caps"&gt;COM&lt;/span&gt;/CORBA marshalling mechanism, so no streaming data or parsing data until the entire document has been received, parsed into an &lt;span class="caps"&gt;XML DOM&lt;/span&gt; tree, and then mapped into an in-memory object tree. For large amounts of data, forget it.&lt;/li&gt;
		&lt;li&gt;&lt;span class="caps"&gt;WSDL&lt;/span&gt; has a lot of syntax to map procedure names/arguments onto &lt;span class="caps"&gt;HTTP&lt;/span&gt;. Contrast this to &lt;span class="caps"&gt;REST&lt;/span&gt;, which embraces the inherent naming conventions of &lt;span class="caps"&gt;HTTP&lt;/span&gt; and applies them to a simple procedural call model&lt;/li&gt;
		&lt;li&gt;The assumption of these tools is that you will use their &lt;span class="caps"&gt;SOAP&lt;/span&gt; wizards instead of rolling your own code. The wizard is meant to be the only way, not an additional way.&lt;/li&gt;
		&lt;li&gt;In fact, the idea that &lt;span class="caps"&gt;SOAP &lt;/span&gt;= Simple Object Access Protocol has become a profound irony.&lt;/li&gt;
	&lt;/ol&gt;


	&lt;p&gt;In his presentation, Mr. Ruby points to &lt;span class="caps"&gt;PHP&lt;/span&gt; as an alternate model. &lt;span class="caps"&gt;PHP&lt;/span&gt; is not really a pretty programming model and it tends to shy away from enforcing higher-level abstractions in favor of lower-level models. But, it is precisely for this reason that &lt;span class="caps"&gt;PHP&lt;/span&gt; has succeeded where many other dynamic web application programming models have failed. Indeed, as it says in the page &lt;a href="http://www.oracle.com/technology/pub/articles/php_experts/rasmus_php.html"&gt;Do You &lt;span class="caps"&gt;PHP&lt;/span&gt;?&lt;/a&gt;&lt;/p&gt;


	&lt;blockquote&gt;
		&lt;p&gt;Database abstraction is mostly a myth. There is nothing wrong with direct database calls&amp;#8217; making use of all the tricks and cheats your chosen database has to offer, to tweak as much performance as possible out of it.&lt;/p&gt;
	&lt;/blockquote&gt;


	&lt;p&gt;And this is the kicker here. Complicated database models tend to abstract away the lower level details of individual databases, even when those details can be the difference between fast and sluggish performance. Remote invocation models like &lt;span class="caps"&gt;SOAP&lt;/span&gt; abstract away the details of the underlying calling mechanism, even when tweaking &lt;span class="caps"&gt;HTTP&lt;/span&gt; requests can be the difference between a fast web app and a slow one. The lower-level mechanism might require more work for the developer, it might be ugly as sin, and it might be wrong and inefficient on some levels, but it works, and more importantly, it works &lt;em&gt;quickly&lt;/em&gt;. Because ultimately, the customer doesn&amp;#8217;t care what technology is used on the backend, they just want their data fast.&lt;/p&gt;


	&lt;p&gt;Bringing it back to my own experience, I once had to work on an application where we searched a remote document repository via &lt;span class="caps"&gt;SOAP&lt;/span&gt; and got metadata back on matching documents in &lt;span class="caps"&gt;XML&lt;/span&gt;. The service would send back all matching results for a query and in some cases, this would result in returning 150000 documents over 5 minutes of streaming &lt;span class="caps"&gt;XML&lt;/span&gt; to us. Knowing that the user probably would want to see data as quickly as possible, I decided it would be good to render whatever data I got after I received 10000 documents and tell the user to perhaps narrow their search down. And I tried to do this in &lt;span class="caps"&gt;SOAP&lt;/span&gt; in Visual Studio, and I failed. I could error out completely, but the mechanism had abstracted away the underlying &lt;span class="caps"&gt;XML&lt;/span&gt;-over-HTTP communication that I had no hooks to get lower level.&lt;/p&gt;


	&lt;p&gt;And so, I chucked it out and went back to basics. The upcoming call to the remote service was faked by filling in an &lt;span class="caps"&gt;XML&lt;/span&gt; string I grabbed from the original &lt;span class="caps"&gt;SOAP&lt;/span&gt; call via a packet sniffer. On the return, my program screams through the data with stream-based &lt;span class="caps"&gt;XML&lt;/span&gt; parsing. Once I hit 10000 records, then I can stop reading the input stream, display what I have, and tell the user that they need to narrow their search criteria. All within 30 seconds.&lt;/p&gt;


	&lt;p&gt;Those people who use &lt;span class="caps"&gt;SOAP&lt;/span&gt; are probably horrified by this and would rightly point out that I had to do a lot of lower-level work to get some of the same functionality promised by the one-click higher-level &lt;span class="caps"&gt;SOAP&lt;/span&gt; abstraction. But I think that&amp;#8217;s precisely the problem. I needed something to work, and I didn&amp;#8217;t need as much for it to be pretty. The &lt;span class="caps"&gt;SOAP&lt;/span&gt; framework locked me into a particular model, and once I needed more than that, it failed to deliver. Abstraction is nice, but abstraction always reduces speed, abstraction always reduces flexbility. In most cases, it is possible to strike a balance where the abstraction helps more than it hurts, but until &lt;span class="caps"&gt;SOAP&lt;/span&gt; is able to handle the heavy lifting needed for serious web work, it isn&amp;#8217;t worth my time.&lt;/p&gt;</description>
      <pubDate>Sat, 16 Apr 2005 10:43:00 -0700</pubDate>
      <guid isPermaLink="false">urn:uuid:7107de4a1709cb2f44e643262e2456ca</guid>
      <author>harrisj</author>
      <link>http://www.nimblecode.com/articles/2005/04/16/radical-simplification</link>
      <category>Web Services</category>
      <category>soap</category>
      <category>rss</category>
      <trackback:ping>http://www.nimblecode.com/articles/trackback/16</trackback:ping>
    </item>
  </channel>
</rss>
