<?xml version="1.0"?>
<?xml-stylesheet href="/transform" type="text/xsl"?>
<!DOCTYPE html>
<html xmlns="http://www.w3.org/1999/xhtml" xmlns:bibo="http://purl.org/ontology/bibo/" xmlns:bs="http://purl.org/ontology/bibo/status/" xmlns:ci="https://vocab.methodandstructure.com/content-inventory#" xmlns:dct="http://purl.org/dc/terms/" xmlns:foaf="http://xmlns.com/foaf/0.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:xhv="http://www.w3.org/1999/xhtml/vocab#" xmlns:xsd="http://www.w3.org/2001/XMLSchema#" lang="en" prefix="bibo: http://purl.org/ontology/bibo/ bs: http://purl.org/ontology/bibo/status/ ci: https://vocab.methodandstructure.com/content-inventory# dct: http://purl.org/dc/terms/ foaf: http://xmlns.com/foaf/0.1/ rdf: http://www.w3.org/1999/02/22-rdf-syntax-ns# xhv: http://www.w3.org/1999/xhtml/vocab# xsd: http://www.w3.org/2001/XMLSchema#" vocab="http://www.w3.org/1999/xhtml/vocab#" xml:lang="en">
  <head>
    <title property="dct:title">The State of Web Development, Continued</title>
    <base href="https://doriantaylor.com/the-state-of-web-development-continued"/>
    <link href="document-stats#EatqZuKfvZxGW_TZTr-h3K" rev="ci:document"/>
    <link href="elsewhere" rel="alternate bookmark" title="Elsewhere"/>
    <link href="this-site" rel="alternate index" title="This Site"/>
    <link href="http://purl.org/ontology/bibo/status/published" rel="bibo:status"/>
    <link href="" rel="ci:canonical" title="The State of Web Development, Continued"/>
    <link href="lexicon/#EzqXIsriaILFcWjXdS7FbI" rel="dct:audience" title="Software Developer"/>
    <link href="person/dorian-taylor#me" rel="dct:creator" title="Dorian Taylor"/>
    <link href="person/dorian-taylor" rel="meta" title="Who I Am"/>
    <link about="./" href="3f36c30c-6096-454a-8a22-c062100ae41f" rel="alternate" type="application/atom+xml"/>
    <link about="./" href="f07f5044-01bc-472d-9079-9b07771b731c" rel="alternate" type="application/atom+xml"/>
    <link about="./" href="this-site" rel="alternate"/>
    <link about="./" href="elsewhere" rel="alternate"/>
    <link about="./" href="e341ca62-0387-4cea-b69a-cdabc7656871" rel="alternate" type="application/atom+xml"/>
    <link about="verso/" href="3f36c30c-6096-454a-8a22-c062100ae41f" rel="alternate" type="application/atom+xml"/>
    <link about="verso/" href="this-site" rel="alternate"/>
    <link about="verso/" href="elsewhere" rel="alternate"/>
    <meta content="the-state-of-web-development-continued" datatype="xsd:token" property="ci:canonical-slug"/>
    <meta content="This is the second installment of my observation of the state of Web application development, along with my vision for the kind of system I would like to use." name="description" property="dct:abstract"/>
    <meta content="2010-05-20T08:30:44+00:00" datatype="xsd:dateTime" property="dct:created"/>
    <meta content="the-state-of-web-development-continued" property="dct:identifier"/>
    <meta content="2010-05-20T08:32:27+00:00" datatype="xsd:dateTime" property="dct:issued"/>
    <meta content="2010-05-20T08:34:29+00:00" datatype="xsd:dateTime" property="dct:modified"/>
    <meta content="2010-05-20T09:07:13+00:00" datatype="xsd:dateTime" property="dct:modified"/>
    <meta content="2022-05-31T04:18:52+00:00" datatype="xsd:dateTime" property="dct:modified"/>
    <meta content="2022-05-31T15:10:50+00:00" datatype="xsd:dateTime" property="dct:modified"/>
    <meta about="person/dorian-taylor#me" content="Dorian Taylor" name="author" property="foaf:name"/>
    <meta content="summary" name="twitter:card"/>
    <meta content="@doriantaylor" name="twitter:site"/>
    <meta content="The State of Web Development, Continued" name="twitter:title"/>
    <meta content="This is the second installment of my observation of the state of Web application development, along with my vision for the kind of system I would like to use." name="twitter:description"/>
    <object>
      <nav>
        <ul>
          <li>
            <a href="a-brief-and-fuzzy-history-of-web-application-development" rev="dct:references" typeof="bibo:Article">
              <span property="dct:title">A Brief and Fuzzy History of Web Application Development</span>
            </a>
          </li>
          <li>
            <a href="document-stats#EatqZuKfvZxGW_TZTr-h3K" rev="ci:document" typeof="qb:Observation">
              <span>urn:uuid:6ada99b8-a7ef-4671-a196-fd3653afe877</span>
            </a>
          </li>
        </ul>
      </nav>
    </object>
  </head>
  <body about="" id="E52SWeWfBLfeze76rMJ4XJ" typeof="bibo:Article">
    <p style="text-align: center; font-weight: bold"><a rel="dct:references xhv:prev" rev="next" href="a-brief-and-fuzzy-history-of-web-application-development" title="A Brief and Fuzzy History of Web Application Development">This is the second of two pieces.</a></p>
    <section id="Ef3Lpx2y9Y445MqhaOqPIJ">
      <p>Perhaps it is my early exposure to the relatively primitive, close-to-the-metal technologies of <acronym title="Common Gateway Interface">CGI</acronym> and <abbr title="World-Wide Web">Web</abbr> server <acronym title="Application Programming Interface">API</acronym>s which has coloured my thinking, but I wonder if we're overlooking an opportunity to provide a much more powerful and seamless experience than we currently are. In its most raw form, the <abbr title="World-Wide Web">Web</abbr> is stateless, anonymous and <em>extremely</em> loosely-coupled. This means that anything that can understand <acronym title="Hypertext Transfer Protocol">HTTP</acronym> and <acronym title="Hypertext Markup Language">HTML</acronym> can also move information back and forth, and navigate between resources. <a href="http://tools.ietf.org/html/rfc2616" title="RFC 2616 - Hypertext Transfer Protocol -- HTTP/1.1" rel="dct:references">The current incarnation of the protocol</a> was explicitly designed to capitalize heavily on <a href="http://en.wikipedia.org/wiki/Content_negotiation" title="Content negotiation &#x2014; Wikipedia" rel="dct:references">content negotiation</a>, <a href="http://en.wikipedia.org/wiki/Web_cache" title="Web cache &#x2014; Wikipedia" rel="dct:references">caching</a> and <a href="http://en.wikipedia.org/wiki/Proxy_server" title="Proxy server &#x2014; Wikipedia" rel="dct:references">proxies</a>. Content was intended to be transformed, filtered, sliced, diced and julienned. We seem to have forgotten about a great deal of this functionality, and only venture there when the situation incontrovertibly demands it. Many sites nowadays simply won't work outside of a conventional browser with <a href="http://en.wikipedia.org/wiki/HTTP_cookie" title="HTTP cookie &#x2014; Wikipedia" rel="dct:references">cookies</a> and <a href="http://en.wikipedia.org/wiki/JavaScript" title="JavaScript &#x2014; Wikipedia" rel="dct:references">JavaScript</a> enabled. <a href="http://www.w3.org/TR/html5/" title="HTML5" rel="dct:references">The impending <acronym title="Hypertext Markup Language">HTML</acronym>5 specification</a> is introducing <a href="http://www.w3.org/TR/webdatabase/" title="Web SQL Database" rel="dct:references">its own <acronym title="Structured Query Language">SQL</acronym> database</a>, which will enable browsers to store even <em>more</em> complex application state.</p>
    </section>
    <section id="Enh78ikENC-ASGbBHaIUtJ">
      <h2>Take Your App and Shove It</h2>
      <p>I suppose I find this part most irksome, because to me the <abbr title="World-Wide Web">Web</abbr> isn't about <em>building apps</em>, it's about <em>placing and finding information</em> and moving data from one place to another. <em>Every</em> <abbr title="World-Wide Web">Web</abbr>-based system reduces to this; it doesn't matter how it is applied. When we cast a system as an <em>application</em>, however, we frame otherwise generically-applicable data, information or content as being for a particular <em>purpose</em>, and that taints the entire experience.</p>
      <p>Possibly the most confusing is the treatment of the <abbr title="World-Wide Web">Web</abbr> <acronym title="Application Programming Interface">API</acronym>, not to be confused with <em>server</em> <acronym title="Application Programming Interface">API</acronym>s. What <a href="http://roy.gbiv.com/" title="Roy T. Fielding" rel="dct:references">Roy Fielding</a> has been trying to tell us for the last ten years is that <acronym title="Hypertext Transfer Protocol">HTTP</acronym> <em>is</em> the <acronym title="Application Programming Interface">API</acronym>. And he should know after all: he designed the protocol. He also coined the term and <a href="http://www.ics.uci.edu/~fielding/pubs/dissertation/rest_arch_style.htm" title="Fielding Dissertation: CHAPTER 5: Representational State Transfer (REST)" rel="dct:references">the idea behind <acronym title="Representational State Transfer">REST</acronym></a>, which has been co-opted, corrupted and abused by an ignorant and unappreciative developer community.</p>
      <h2>But the Data is Already There</h2>
      <p>Many <acronym title="Application Programming Interface">API</acronym>s, even those that claim to be <acronym title="Representational State Transfer">REST</acronym>ful, do little more than provide the same information as that which is on the pages, or the same functionality as submitting certain forms on a given site. They do so inside a sandbox of <a href="http://en.wikipedia.org/wiki/Shared_secret" title="Shared secret &#x2014; Wikipedia" rel="dct:references"><acronym title="Application Programming Interface">API</acronym> keys</a>, dodgy cryptographic handshakes and <a href="http://en.wikipedia.org/wiki/Rate_limiting" title="Rate limiting &#x2014; Wikipedia" rel="dct:references">rate limiting</a>. They then demand the creation of wrappers to translate their baroque innards into usable software libraries, one for each programming language. The benefit of this is supposed to be access to a conduit of reliable, machine-readable data, but I wonder how much more effort it would be just to create a <a href="http://en.wikipedia.org/wiki/Web_scraping" title="Web scraping &#x2014; Wikipedia" rel="dct:references"><abbr title="World-Wide Web">Web</abbr> scraper</a> which does the same thing. I have personally written scrapers to fill the gaps in <acronym title="Application Programming Interface">API</acronym>s that lacked information I wanted, and haven't had to repair them any more than any <acronym title="Application Programming Interface">API</acronym> wrapper I've used. As a bonus, I don't have to fool around with an <acronym title="Application Programming Interface">API</acronym> key, some weird token-passing login mechanism or try to tiptoe around what often turns out to be arbitrary and officious usage accounting.</p>
      <p>Here's the thing: the data, <em>whatever data</em>, is already on the page. You can go fetch it by visiting its <acronym title="Uniform Resource Identifier">URI</acronym>. Then you can extract it with whatever tools you see fit. Don't like the extra overhead of superfluous <acronym title="Hypertext Markup Language">HTML</acronym>, or afraid a change to the layout will torpedo your data pipeline? Fine, supply a more machine-friendly variant of the same data, and put it at more or less the same address. A few outfits do this, but only a few. <a href="http://apiwiki.twitter.com/Twitter-API-Documentation" title="Twitter API Wiki / Twitter API Documentation" rel="dct:references">Twitter is one of them</a>. In addition to opening up to third-party developers, they seem to use their <acronym title="Application Programming Interface">API</acronym> to drive their own site. They also provide an option to use plain-Jane stateless <acronym title="Hypertext Transfer Protocol">HTTP</acronym> authentication, sans cookies, <a href="http://en.wikipedia.org/wiki/Shared_secret" title="Shared secret &#x2014; Wikipedia" rel="dct:references">shared secrets</a> or bogus crypto. Nice. <em class="donthyphenate">Almost</em>.</p>
      <h2>Easier, But Not Orders of Magnitude Easier</h2>
      <p>The problem is that their machine-friendly representations of data objects are <em>their</em> representations. They have their own idiosyncratic understanding of what a <em>user</em> object is, for example. Even though they supply the data in a vendor-neutral <em>syntax</em>, like <acronym title="Extensible Markup Language">XML</acronym> or <acronym title="JavaScript Object Notation">JSON</acronym>, <em>I</em> still have to translate the <em>semantics</em> of what each of the fields <em>means</em> to my internal representation. This means I can't just haul in data from Twitter, or any other <acronym title="Application Programming Interface">API</acronym> provider, with a generic data interface. I need to write an additional layer of code, specific to them. This is the difference between writing one adapter for <em>all</em> <abbr title="World-Wide Web">Web</abbr> sites, and writing one for <em>each</em> site I'm interested in.</p>
      <h2>There's an App for That</h2>
      <p>This problem, by the way, is <em>exactly</em> the one that the <a href="http://www.w3.org/2001/sw/" title="W3C Semantic Web Activity" rel="dct:references">Semantic Web</a> was designed to solve. If a <abbr title="World-Wide Web">Web</abbr> site provides its data as <a href="http://www.w3.org/RDF/" title="RDF - Semantic Web Standards" rel="dct:references"><acronym title="Resource Description Framework">RDF</acronym></a>, the lingua franca of the Semantic Web, it can be unambiguously understood what every single little nugget of data is intended to represent, and it can be done without <em>any</em> site-specific code. If the site in question understands <acronym title="Resource Description Framework">RDF</acronym>, then the same applies for data coming from other sources, like me. With <a href="http://www.w3.org/TR/xhtml-rdfa-primer/" title="RDFa Primer" rel="dct:references"><acronym title="Resource Description Framework in Attributes">RDFa</acronym></a>, even conventional <acronym title="Hypertext Markup Language">HTML</acronym> pages can be imbued with semantic data, obviating the need for data consumers to rely on custom scrapers or error-prone heuristics. This I see greatly improving search and findability, simplifying client-side programming and opening up a number of new, interesting and valuable uses for the data.</p>
      <h2><a href="http://en.wikipedia.org/wiki/Resource_oriented_architecture" title="Resource oriented architecture &#x2014; Wikipedia" rel="dct:references"><em>Resource</em></a>, not <a href="http://en.wikipedia.org/wiki/Service_oriented_architecture" title="Service oriented architecture &#x2014; Wikipedia" rel="dct:references"><em>Service</em>-Oriented Architecture</a></h2>
      <p>There is one other consideration, and that is the <em>siteness</em> of a site. It is best expressed neither as a folder full of files on a server, nor as a monolithic application off in the cloud, but as a collection of potentially disparate resources under the management of a particular business entity. Any resource on the <abbr title="World-Wide Web">Web</abbr> can point to and <em>use</em> any other resource <em>anywhere</em> else with the same trivial effort. It can even do so across organizational boundaries, unless the target organization refuses to cooperate.</p>
      <aside role="note" id="EuPaiRqnB2zKDxbOlIfVDL">
        <p>This is strange behaviour, as the organization in question usually gains on the whole from what has become a perfectly natural form of reference we call <em>linking</em>.</p>
      </aside>
      <p>So if we took all these ideas and put them together, what would it look like? More importantly, what would we gain from it?</p>
      <h2>What are <em>You</em> Going to Do About It?</h2>
      <p>The system I envision is in some ways a <em>conduit</em> for information as much as it is an origin. It interacts heavily with other <abbr title="World-Wide Web">Web</abbr>-based systems, but doesn't completely trust any one of them. It works with <em>all</em> clients, not just the latest browsers, where <em>works</em> is defined as <q>can consume content, follow links and send data</q>. It does not depend on client-side state mechanisms or code, such as cookies or JavaScript, though it may use them to augment the experience. It is friendly and forthcoming to robots and search engines, though resilient to abuse. It relays data to and from third parties, but maintains its position between its users and other entities to ensure it can deliver on its promises. It records every click for the most comprehensive statistical analysis. Every datum is represented in a semantic structure for every representation capable of doing so, and every <acronym title="Uniform Resource Identifier">URI</acronym> effectively doubles as an <acronym title="Application Programming Interface">API</acronym> endpoint. Part of it could reside in the cloud, while another could easily live in your office or hall closet.</p>
      <p>The gain, I hope, is manifold. By reducing the command language back to plain <acronym title="Hypertext Transfer Protocol">HTTP</acronym>, I can enfranchise everybody, regardless of development platform. This includes operations within the confines of the system itself, potentially composing it of many different platforms running in many different places, each contributing bits and pieces of functionality. By representing all my data as <acronym title="Resource Description Framework">RDF</acronym>, I provide a clear meaning for each structure. I can also borrow established vocabularies made by people who have much more time to consider how such structures ought to be, and which are much more likely to be adopted by other people. I can likewise consume data from any appropriate source and weave it into my own. By maximizing the system's statelessness and operability, I no longer have to worry about turning paranoid users or those with antiquated browsers away, even though their experience may be decidedly clunkier. Mostly, I'm interested in demonstrating how responsible <abbr title="World-Wide Web">Web</abbr> development behaviour can be hedged by taking away the bulk of the work that gets in its way.</p>
      <p>Oh, and this is something I am actually working on, inching toward completion between more pressing matters. None of it is technically very difficult, it's more of a matter of making thousands of decisions of how I want it to behave. The actual product, so far, is surprisingly compact. If I succeed, you won't be able to tell I'm even using it. No promises as to when it'll be ready though, don't want to jinx it.</p>
    </section>
  </body>
</html>
