Restful services in Java

Over the years there have been different methods of for communicating between heterogeneous systems.  Each of these methods have to deal binary messaging.  Some of the different protocols that have been used are as follows.

  • Remote procedure calls (RPC)
  • Distributed Component Object Model (DCOM)
  • Common Object Request Broker Architecture (CORBA)
  • Simple object access protocol (SOAP)
  • Windows Communication Foundation (WCF)

These protocols are of varying complexity and some of the descriptions that have been used to describe them are complexity, rigid, complex, heavyweight and complicated.

Each time the technology wheel turns a new protocol is created with the goal to create something that is powerful and lightweight.

Restful web services is an attempt at providing a lightweight but scaleable communications protocol that can be called from any platform.  It uses a simple URL instead of creating and passing complicated XML structures

This should be a very simple way of submitting information or retrieving data.  A colleague once recommended that I create my own web services for processing my weekly expenses while I was on the road.

At that time, it seemed like overkill to create such a solution in order to process anywhere from 5 to 10 expense items per week.

  • Setup a computer with web server
  • Program a web service to accept the price data
  • Create some GUI process for entering the data

I did have the interest in the project but ended up focusing my efforts on dabbling in the hardware arena by creating a LED cube.  Eventually, my interest has come back to web services.

Of course as what often happens is that you cannot start something without doing something else first – in this case all the prerequisite software.

My laptop is a bit of a mess so I choose to create a small virtual machine and do all of my work there.  This is actually a extremely interesting use of those extra cpu cycles and could become common for even basic computer users in the future.  I hope to go into that at a later point.

For working with restful web services I needed to install the following.

Once everything was setup, I did get a chance to create both a a server and a client.  I will not actually setup my own restful server setup  for remotely doing my expenses but I may end up using the technology for something else in the future.

The next few blog entries create a few simple examples to put the technology through its paces.

Difference between Soap and Rest protocols.

http://blog.smartbear.com/apis/understanding-soap-and-rest-basics/

This entry was posted in programming, Setup From Scratch and tagged , , . Bookmark the permalink.