Last REST Post of 2007

Here's the take-away from the past year's discussion about REST and geospatial. My own take, that is. There are differences of opinion among the participants of the Geo-Web-REST group.

REST is an architectural style, not an API. When you hear or read "... REST API ...", that's a smell, a signal that something might not be quite right inside.

REST is the architectural style of the World Wide Web. "Web API" is a more meaningful term, although not all Web APIs are RESTful. Some are GETSful.

The OGC service architecture is not RESTful. The style of the OGC architecture is non-RESTful CGI/RPC. Feature, map, and coverage resources are kept hidden behind service endpoints. We're still partying like it's 1999.

GML is compatible with REST, but XML Schema is still a wretched beast and there are no XLink-traversing GeoWeb browsers of note.

Look to Google Earth and KML for REST inspiration. It's about the links. Also look to Google's AtomPub-ish APIs for YouTube, Picasa, and OpenSocial. There's no transactional WFS involved there, and that's something to think about. Google chose AtomPub for wider interoperability.

REST is not a silver bullet. Distributed applications are hard.

These are the tenets of REST:

  • Give every “thing” an ID

  • Link things together

  • Use standard methods

  • Resources with multiple representations

  • Communicate statelessly

Do read and recommend Stefan Tilkov's Brief Introduction to REST, from which the tenets above are taken. It's excellent.

Disregard the Emerging Technology: Geospatial Web Services and REST article in Directions. I don't care who linked you to it; they probably didn't read it very closely. This sounds mean, but that article will make you dumber about REST.


Re: Last REST Post of 2007

Author: Norman Barker

Sean, I have just read this and it makes some good arguments - perhaps SOAP can play after all, and the OGC have ebRIM :-) I have been enjoying the discussion of REST on this blog - thanks!

Re: Last REST Post of 2007

Author: Allan Doyle

Ganesh talks a good game. But remember that HTTP is itself a dumb-network/smart endpoint protocol that rides on top of TCP (and thus can also make use of IPsec). SOAP tends to ride on top of HTTP, and is generally run at a higher level on the networking stack than HTTP. True, SOAP can run on SMTP, or any other protocol, but as implemented it's on HTTP probably 99+% of the time. Ergo, there is no protocol advantage. The entire smackdown is moot.

Re: Last REST Post of 2007

Author: Allan Doyle

And, just one more thing... it strikes me that if you were to apply REST principles to SOAP you might just come up with something approaching "SOAP message with WS-Addressing headers". In other words, REST is a set of architectural constraints that can be embodied on any distributed system that has the ability to provide unique IDs for resources which can themselves contain links to other resources.

Re: Last REST Post of 2007

Author: Keyur

Last REST post? 13 days is a lifetime.