Information Technology Reference
In-Depth Information
Rest Easy with REST Services
For a variety of reasons, it's good to maintain a service interface to the
functions of IAM. Services are the way to hide the gory details of the
implementation from client applications. The traditional approach to
building services involves the use of SOAP-based web services. Without
getting into the larger SOAP-versus-REST debate, we find that IAM's user
management functionality is extremely intuitive and easy to build using
REST-based services.
For those unfamiliar with REST, think of it as a way to interact with a web
application, with just a few special features. One, although the interaction is
over HTTP, the content need not be HTML rendered by a browser. It could
be any data structure sent from one application to another. Two, the
interaction can be defined quite rigorously, so that the “service contract” so
beloved of SOA practitioners is exposed in a recognisable way. Three,
although the HTTP protocol appears to be synchronous and also an
“unreliable” protocol, it is possible to model asynchronous and reliable
behaviour using some standard techniques.
The REST style consists of modelling the various aspects of an application
domain as “resources”, and dealing with other systems in terms of
“representations” of those resources. Representations are somewhat akin to
the immutable Data Transfer Objects used in distributed computing.
What makes REST simple is the standardisation of its service interface. There
are standard verbs for operations and standard status codes that they
return. The resources managed by a server are also exposed in a fairly
standard way, i.e., as URIs. In true service-oriented fashion, the actual
implementation is completely opaque to the outside world. Only the URIs
representing resources, the standard verbs and the standard status codes
are ever known by external systems. REST is another great decoupling
technique, effectively minimising and formalising the dependencies between
service consumers and service providers.
The following diagram helps to understand the REST idiom at a glance.
 
 
Search WWH ::




Custom Search