Written By: Pankaj Srivastava
Email: - PankajShrivastav6@gmail.com
What are SOA, Services and Messages in
Before we talking about SOA and its Principal what will do we’ll move back
to 1980 where people talk in terms of functional Programming so people
coded in terms of functions and they also put down some best practices like
top down approach in another words always entered function like example
Functional Programming, top to down Approach 1980
function AddNum(int num1,int num2)
//so here is always go to top to down function
Everything was good in functional Programming but there are big issues
with functional Programming.
First was Maintainability or I can say rather understanding somebody else
Second was Reusability it is not the point is reusability was not there for
example if you take up a C language you can reuse a function by putting
that into c file and then using include keywords but it was physical include,
so in another words you need to include whole file with the main source
code which needs to basically reuse the program of the function so the
reusability was not so flexible and first important was maintainability .
So, People move towards 1990s and the reusability was the agenda
The Reusability Agenda 1990s, OOPS
So here people said let’s talk in terms of Object of real world, So here
people started thinking in terms of classes and Objects so basically you can
create a class and then reuse the class again and again by creating object of
Class for example:-
Collection of address
So example here I can create object of Students Class and reuse it again and
again. Everything was well in 1990 but one of the point which we forget to think
about was that the classes should also needs to interact outside the application so
You can make a class in .NET but if you want to call that class using java it was
very difficult because every company like .NET Belongs to MICROSOFT and JAVA
Made In .NET
Made In JAVA
Need to Communicate
Belongs to Sun microsystem, So everybody have their own propriety the way of
Compiling Programs and Due to this it was very difficult to call classes made in
one language to another language so people said that defiantly this is the
problem and they said let’s think in terms of MESSAGES.
Issue with the OOP’s Approach is that cross interoperability between languages
does not exist.
So people started thinking in terms of Messages in 2000 era, people said let’s not
talk in terms of object, classes ,propriety compilers and so on ,let’s talk in terms
of message now this message can be in form of xml or in form of csv or in form of
JSON object, whatever it is
So basically if you want to call about .Net function or if you want to access the
Voucher class so the java application can send XML message and .NET can read
that xml Message and create an object of the Voucher class, So with this came in
loose coupling ,So now either .net or either Java don’t need to think in terms of
Made in JAVAMade in .NET
their classes,objects,dlls,and there compiling methodology they need to only
think in terms of messages and then the programming industry decided that lets
do one thing let’s take up this messages and make them more standardize so then
we can interopt between any Programming language.
One more thinking was change other that the messages which we need to think in
terms of Services.
So what are the Services??
Services are nothing it’s a logical encapsulation of self-contained business
So here I have three Services
Now basically I can take up the kitchen and attached to a one bedroom Or I can
take up the kitchen and attached to some hotel Room, So in other words kitchen
is self-contained Business functionality, Second I can change the waiter without
even thinking about kitchen or either I can replace a waiter to another waiter
without changing kitchen .
So the other aspect of self-contained business functionality, we should be able to
change and modify those services without even without affecting other services
in isolated manner.
So important thing to understand that Services are not the classes or any
components or not a namespaces or not a group of classes.
But they are self contains working business functionality So these two terms
Services and messages are nothing it’s a building block of Service Oriented
Counter Kitchen Waiter
What are the Standard and characteristics Services and Messages Should
1. Services should be self-contained and it should communicate using
2. Services should be able to define themselves.
3. Service should be maintained in repository where we can find them
4. Message format should be standard and work across the platform
e.g. Microsoft follows SOAP
5. Message should be able to communicate async., reliably and in a secured
Communicate using messages
Follow industry Standard
Describe and Discover Services.
SOA is an architectural style for
building business applications using
loosely coupled services which act
like black boxes, and can be
arrange to achieve a specific
functionality by linking together.