Before we head out on a 3 day weekend for memorial day it seems like a good time to talk about a Handel Research project Lee Pepper has been working on named bandicoot. REST stands for Representational State Transfer and has been popularized by Google, FaceBook and Twitter. Rest involves using the low level HTTP protocol to transfer data back and forth. Currently in our production systems we have been using WCF and SOAP messages.
Lets explore this idea a bit more..
So to run a Google search for “hello” you could type in to the browser
http://www.google.com/search?q=hello
What this does is uses a query parameter. What if querying RiteTrack was that easy? Well with bandicoot it is.
To recover data all we need to is go to a website like this
http://localhost/api.ashx/dtPerson/85056
What this does is it pulls back a dtPerson record with personid 85056.
We can rewrite this as
http://localhost/api.ashx/dtPerson?q=where personid=85056.
We can have any more fun by typing
http://localhost/api.ashx/dtPerson/85056?output=html to get..
Using the format parameter we can return .json .xml .csv and .html from the request. No matter what language you are in, you will be able to consume the data.
So we have demonstrated that the average web developer can now pull data from the system using advanced queries and provide readable results. The system is fully rest capable and we are examining taking this system to production.
One was last thought though.. Why would we abandon our production WCF system. For that I'll leave you with a graph of 500 requests. (Red is Bandicoot, Blue is WCF)
Lee Pepper has given us a 640% speed increase. Pretty impressive!