Service-Oriented Architecture: Prof Ehab E. Hassanien Dr. Dina Ezzat

You might also like

Download as pdf or txt
Download as pdf or txt
You are on page 1of 14

Service-Oriented

Architecture
Prof Ehab E. Hassanien
Dr. Dina Ezzat
Fundamentals
Programming Methods

Functional programming. This includes languages such as Erlang and
Scala, which are used for telecommunications and fault tolerant systems.

Structured or modular programming. This includes languages such as
PHP and C#.

Imperative programming. focuses on describing how a program operates.

Declarative programming. This programming method focuses on what
the program should accomplish without specifying how the program
should achieve the result. Languages include Prolog and Lisp.

Logical programming. This method, which is based mostly in formal logic
and uses languages such as Prolog, contains a set of sentences that
express facts or rules about a problem domain. It focuses on tasks that
can benefit from rule-based logical queries.

Object-Oeinted Programming focuses on models and includes C++ and
Java.
Object-Oriented Programming
Object-oriented programming (OOP) is a
computer programming model that organizes
software design around data, or objects, rather
than functions and logic. An object can be defined
as a data field that has unique attributes and
behavior.
– OOP focuses on the objects that developers want to
manipulate rather than the logic required to manipulate
them.
– This approach to programming is well-suited for
programs that are large, complex and actively updated
or maintained.
The Benefits of OOP

Modularity. Encapsulation enables objects to be self-contained, making
troubleshooting and collaborative development easier.

Reusability. Code can be reused through inheritance, meaning a team
does not have to write the same code multiple times.

Productivity. Programmers can construct new programs quicker through
the use of multiple libraries and reusable code.

Easily upgradable and scalable. Programmers can implement system
functionalities independently.

Interface descriptions. Descriptions of external systems are simple, due
to message passing techniques that are used for objects communication.

Security. Using encapsulation and abstraction, complex code is hidden,
software maintenance is easier and internet protocols are protected.

Flexibility. Polymorphism enables a single function to adapt to the class it
is placed in. Different objects can also pass through the same interface.
Criticism of OOP
The object-oriented programming model has been
criticized by developers for multiple reasons. The
largest concern is that
– OOP overemphasizes the data component of software
development and does not focus enough on
computation or algorithms.
– Additionally, OOP code may be more complicated to
write and take longer to compile.
SOA vs. OOP


OOP uses objects to build systems, and it tends
marry data and behavior.

SOA uses services to build systems.

Services tend to separate data from behavior. In
an SOA, the separation between data and
behavior is often obvious.
OOP is a programming paradigm. SOA is a system architecture concept.SOA can be implemented using OO
code (or any other type of coding, it does not matter). OOP can be part of a SOA architecture or can be used
outside of that architecture. OO and SOA are two different concepts (level wise). We could for example
compare SOA based architecture to non-SOA based architecture or compare OOP to Procedural Programming
used in languages such as COBOL II. However, comparing SOA to OO would not be valid.


SOA needs OOPS working underneath it.


SOA is a "strategy" to make the entire application/service distributed and reliable


Think of a Service as a black box. The way the service is built internally is not your concern (this is generally
a good thing). You mainly focus on consuming the service via its API. Whether you do this via classes in an
OO program or even via URL request on the browser

as in this example:
http://ichart.finance.yahoo.com/table.csv?s=IBM&a=1&b=1&c=2010&d=1&e=1&f=2012&g=d&ignore=.csv


if you click this link Yahoo Finance will get you a CSV file of stock information.
An Application

The term application has different meanings in different
contexts. Some define an application as a single computer
program, which means a single executable.

Others define an application as a collection of more than
one computer program that work together to provide
some functionality. Such is the case for many Internet-
based applications.

However, in this course, we will use the term in the more
restricted sense to mean only a single executable or
computer program. This will help avoid any confusion
concerning its usage.
Distributed Computing

By distributed computing, we always mean more than
one application (or executable). These programs or
applications typically run on separate hardware or
machines, but they work together to achieve some
function.


The different applications running on different
computers use some method of communicating among
themselves over a computer network. Some of these
communication methods include sockets, RPC, ORBs,
and asynchronous messaging.
Enterprise
The first is “a business entity,” and the second is “a
project or undertaking that is especially difficult,
complicated, or risky.” These two definitions taken
together give a good sense of the entities we are
interested in.

To be more specific, by enterprise we mean any


large and complex organization that has an equally
large and complex IT system.
Enterprise Software
Enterprise software is designed for a large organization that
typically has its own internal organization, processes, and
business model.
The software must take into account both cross-departmental
dependencies and external business relationships, such as
business partners and external vendors.
Therefore, enterprise software must meet a large number of
different types of requirements. Many of these requirements
are incomplete, unclear, or otherwise conflicting.
Furthermore, the requirements keep changing due to the
market conditions and organizational changes. Because of
these reasons,enterprise software is typically very complex.
Memory Layout Of A Typical Program
The given layout segments can
be broadly classified into two:
– Static Memory Layout –
Text/Code, Data Segments
– Dynamic Memory Layout – Stack
& Heap

Text or Code Segment includes
the machine-level instructions
for the final executable object
file. This section is one of the
key parts of the static memory
structure as it includes the
program’s central logic.
Memory Layout Of A Typical Program (cont)


A new stack-frame is
added to the stack
memory when a new
function is invoked. The
corresponding stack-
frame is removed when
the function returns.

every function has its
own stack-frame, also
known as Activation
record.

You might also like