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

CS6703 GRID AND CLOUD

COMPUTING

Grid Services
Unit 2 Session-1
CS6703 GRID AND CLOUD COMPUTING
Unit 2
UNIT II GRID SERVICES

Introduction to Open Grid Services Architecture (OGSA) –


Motivation – Functionality Requirements – Practical &
Detailed view of OGSA/OGSI – Data intensive grid service
models – OGSA services.

3 Course: GCC Unit: 2; Session: 1 Grid Services


• Web Services
• Grid Services

Course: GCC Unit: 2; Session: 1 Grid Services


4
Web Service. (W3C definition)

• A Web service is a software system


designed to support interoperable
machine-to-machine interaction
over a network.
• It has an interface described in a
machine-processable format
(specifically WSDL).
• Other systems interact with the
Web service in a manner prescribed
by its description using SOAP
messages, typically conveyed using
5 HTTP with an XML serialization in
Course: GCC Unit: 2; Session: 1 Grid Services
• In plain words, they provide a good mechanism to
connect over a network heterogeneous systems.
• For that to happen it uses: WSDL, XML, SOAP…

Course: GCC Unit: 2; Session: 1 Grid Services


6
Sample Interaction

Key things to note:


Request/response

login
Buyer Amazon.com
login ok

buy a book

price information

confirm purchase

Course: GCC Unit: 2; Session: 1 Grid Services


7
The Web Service state machine

2. Client looks up the


service in the registry

1. Service advertises
itself in the registry

3. Client interacts
with the service

Course: GCC Unit: 2; Session: 1 Grid Services


8
Why web services?

• Can we not do above interaction with traditional


client/server protocols
• Yes !
• But,
• We want to talk to any service in the same
language in the same way

Course: GCC Unit: 2; Session: 1 Grid Services


9
Web Services Technologies

The Protocol Stack


 Service Discovery Service Discovery
 UDDI
 Service Description Service Description
 WSDL (XML-based)
 Messaging
XML Messaging
 SOAP (XML-based)
 Service Transport
 HTTP, SMTP etc. Service Transport

Course: GCC Unit: 2; Session: 1 Grid Services


10
XML (Extensible Markup Language)

• A language for describing data


• Platform independent and self-describing
• Good for distributed computing where
heterogeneous systems co-exist

Course: GCC Unit: 2; Session: 1 Grid Services


11
XML - Example

xml start tag


declaration

<?xml version="1.0"?>
<contact-info>
<name>John Smith</name> <company>University of
Florida</company> <phone>352-392-1200</phone>
</contact-info>
</xml>

end tag text


Course: GCC Unit: 2; Session: 1 Grid Services
12
Web Services Interaction

XML

Web Service
User

Resource
(database, CPU,
storage …)

Course: GCC Unit: 2; Session: 1 Grid Services


13
An example scenario

Tell me about your


service
Buyer Amazon.com
WSD (Web service description)

Send a SOAP message (show the soap message in the text


box)
<portType name=“BookService">
Returned SOAP message
<operation name=“buyBook">
<input name=“bookName“
message="tns:bookName"/>
<output name=“price"
message="tns:price"/>
</operation>
</portType>

Course: GCC Unit: 2; Session: 1 Grid Services


14
Typical Web Service Invocation

15
The Web Service state machine

2. Client looks up the


service in the registry
(UDDI) and gets a UDDI
WSDL description

client
1. Service advertises
itself in the registry
3. Client interacts (UDDI)
service
with the service
(SOAP + HTTP
+ XML)
Course: GCC Unit: 2; Session: 1 Grid Services
16
SOAP (Simple Object Access Protocol)

• SOAP is a protocol specification that


defines a uniform way of passing
XML-encoded data
• In also defines a way to perform
remote procedure calls (RPCs) using
HTTP as the underlying
communication protocol
• It is the underlying protocol for all
web services

Course: GCC Unit: 2; Session: 1 Grid Services


1
Structure of SOAP Messages

Soap Message
Envelope (required)
Header (optional)

Body (required)
Fault (optional)

1
XML messaging using SOAP

Application Web Service

SOAP SOAP

Network protocols Network protocols


(HTTP …) (HTTP …)

Course: GCC Unit: 2; Session: 1 Grid Services


1
WSDL (Web Service Description Language)

• Now, we know how to send


messages. But, how do we find out
about the web service interface?
Answer: WSDL !!!
• WSDL provides a way for service
providers to describe the basic
format of web service requests over
different protocols or encodings
• It provides the following information
about the service
• What the service can do
• Where it resides
Course: GCC Unit: 2; Session: 1 Grid Services
2
Contents of a WSDL document

<definitions>
<types>
definition of types........
</types>
<message>
definition of a message....
</message>
<portType>
definition of a port.......
</portType>
<binding>
definition of a binding....
</binding>
</definitions>

Course: GCC Unit: 2; Session: 1 Grid Services


2
portType

• WSDL portType is the most important element of the document


• It defines the operations that can be performed on a web service
<portType name=“Hello">

<operation name=“greeting">

<input name=“name" message=“greetingRequest"/>

<output name=“response” message=“greetingResponse"/>

</operation>

</portType >

Course: GCC Unit: 2; Session: 1 Grid Services


2
Messages and Types

• But, to describe the operation we


also have to identify the messages
that need to be sent and type of the
elements that are sent in the
messages
<message name=“greetingRequest">

<part name=“input" type="xs:string"/>


</message>

<message name=“greetingResponse">

<part name="value" type="xs:string"/>


</message>

• As you can see, various types can be


specified Course:
forGCC the messages
Unit: 2; Session: 1 Grid Services
2
Binding
• The binding element describes the way the message needs to be
encoded (usually using SOAP)
<binding type=“Hello" name=“myBinding"> <soap:binding
style="document" transport="http://schemas.xmlsoap.org/
soap/http" />
<operation> <soap:operation
soapAction="http://example.com/Hello"/>
<input> <soap:body use="literal"/> </input>
<output> <soap:body use="literal"/> </output>
</operation>
</binding>

Course: GCC Unit: 2; Session: 1 Grid Services


2
<definitions name=“Hello" targetNamespace="http://hello.com"
xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
xmlns="http://schemas.xmlsoap.org/wsdl/">
<message name=“greetingRequest">
<part name=“input" type="xs:string"/> </message>
<message name=“greetingResponse">
<part name="value" type="xs:string"/> </message>
<portType name=“Hello"> message
<operation name=“greeting">
<input name=“name" message=“greetingRequest"/>
<output name=“response” message=“greetingResponse"/> portType
</operation>
</portType >
<binding type=“Hello" name=“myBinding"> <soap:binding
style="document"
transport="http://schemas.xmlsoap.org/soap/http" />
<operation> <soap:operation
soapAction="http://example.com/Hello"/>
<input> <soap:body use="literal"/> </input>
<output> <soap:body use="literal"/> </output> binding
</operation>
</binding>
</definitions>

2
UDDI (Universal Description, Discovery and Integration)

• A protocol for finding web services


• Registries of web services can be maintained
• The primary purpose is to find services with
certain qualities

Course: GCC Unit: 2; Session: 1 Grid Services


2
UDDI

• BusinessEntity
• Information about a company
(name of the company, contact
info etc.)
• Kind of company
• BusinessEntity contains
BusinessService elements that
represent the services the
company offers
• Each BusinessService contains
BindingTemplates that describe
the services

Course: GCC Unit: 2; Session: 1 Grid Services


2
stateless vs. stateful web service

• Stateless web services don’t “remember”


information from one invocation to another
whereas stateful Web Services do.
• When Web Services are used just to create
Internet-based applications with loosely coupled
clients and servers, they can be stateless. The
service can be restarted without concern of
previous interactions.
• When Web Services are used to create Grid
Applications, they are generally required to be
stateful.

Course: GCC Unit: 2; Session: 1 Grid Services


2
Stateful web services example

login
Buyer Amazon.com
login ok, your
shopping cart id is
0x800

logout

login and my id is 0x800

Your shopping cart has …

Course: GCC Unit: 2; Session: 1 Grid Services


2
Problems

• No standard on how to do this


• Client needs to have special code
• Some protocol specific features like cookies can
be used

Course: GCC Unit: 2; Session: 1 Grid Services


3
Grid Services

• So, what are these grid services


anyway?
• Grid services are web services that
are customized to grid environment
• Similar to web services they provide
the glue to interact with
heterogeneous systems
• Why do we need them?
• What do they provide?
Course: GCC Unit: 2; Session: 1 Grid Services
3
Web Services vs Grid Services

• Though web services are great, some key things


that are required on the grid are missing
• State management
• Global Service Naming
• Reference resolution
• more …

Course: GCC Unit: 2; Session: 1 Grid Services


3
Web Services vs Grid Services

• Wait a minute ! I can do all those things with web


services, can’t I?
• YES ! You can
• But,
• The standards don’t provide (yet) the required
mechanisms. Work is being done to figure out
the best way to do these things

Course: GCC Unit: 2; Session: 1 Grid Services


3
Achieving Statefulness

• The state is kept in a separate entity called a


resource.
• Each resource has a unique key.

Course: GCC Unit: 2; Session: 1 Grid Services


3
OGSA Introduction

• Grid systems and applications aim to integrate, virtualize


and manage resources and services within distributed,
heterogeneous, dynamic “virtual organizations”
• Items needed
• Computers, application services, data, and other resources
need to be accessed within different organizations
• Standardization
• Open Grid Services Architecture (OGSA)
• Is a service-oriented architecture (SOA), that addresses
the need for standardization by defining a set of core
capabilities and behaviors that address key concerns in
Grid systems

• SOA: A perspective of software architecture that defines


the use of services to support the requirements of
software users. Enables the creation of applications that
are built by combining loosely coupled and interoperable
services
Course: GCC Unit: 2; Session: 1 Grid Services
3
What is the OGSA Standard?

• Acronym for Open Grid Service Architecture

• OGSA define how different components in grid interact

• Open Grid Services Architecture (OGSA) is a set of standards


defining the way in which information is shared among diverse
components of large, heterogeneous grid systems. In this context,
a grid system is a scalable wide area network (WAN) that supports
resource sharing and distribution.

36 Course: GCC Unit: 2; Session: 1 Grid Services


OGSA

• OPEN GRID SERVICES ARCHITECTURE (OGSA)


• VO Management Service.
• Resource Discovery and Management Service.
• Job Management Service.
• … security, data management, etc.

Course: GCC Unit: 2; Session: 1 Grid Services


Architecture of OGSA

 Comprised of 4 main layers

 Physical and Logical Resources Layer

 Web Service Layer

 OGSA Architected Grid Services Layer

 Grid Applications Layer

38 Course: GCC Unit: 2; Session: 1 Grid Services


OGSA Architecture

39 Course: GCC Unit: 2; Session: 1 Grid Services


OGSA Architecture - Physical and Logical
Resources Layer

• Physical resources are: servers, storage, network

• Logical resources manage physical resources

• Examples of logical resources: database managers, workflow managers

Course: GCC Unit: 2; Session: 1 Grid Services


4
OGSA Architecture - Web Services Layer
• Web service is software available online that could interact with other
software using XML
• Consists of Open Grid Services Infrastructure (OGSI) sub-layer which
specifies grid services and provide consistent way to interact with grid
services
• Also extends Web Service Capabilities
Consists of 5 interfaces:
1. Factory: provide way for creation of new grid services
2. Life Cycle: Manages grid service life cycles
3. State Management: Manage grid service states
4. Service Groups: collection of indexed grid services
5. Notification: Manages notification between services & resources

41 Course: GCC Unit: 2; Session: 1 Grid Services


OGSA Architecture - Web Services Layer (OGSI)

OGSI defines the mechanisms to create grid


services
Introduces the notion of grid services and their
special
properties particularly the global pointer GSH (Grid
Service Handle)
42 Course: GCC Unit: 2; Session: 1 Grid Services
OGSA Architecture – OGSA Architected Services - Layer

Classified into 3 service categories

1. Grid Core Services

2. Grid Program Execution Services

3. Grid Data Services

43 Course: GCC Unit: 2; Session: 1 Grid Services


OGSA Architected Services – Grid Core Services

Composed of 4 main types of services:


1. Service Management: assist in installation, maintenance, &
troubleshooting tasks in grid system
2. Service Communication: include functions that allow grid
services to communicate
3. Policy Services: Provide framework for creation,
administration & management of policies for system operation
4. Security Services: provide authentication & authorization
mechanisms to ensure systems interoperate securely

44 Course: GCC Unit: 2; Session: 1 Grid Services


OGSA Architected Services – Grid Program Execution
Services

• Supports unique grid systems in high performance

computing, collaboration, parallelism

• Support virtualization of resource processing

45 Course: GCC Unit: 2; Session: 1 Grid Services


OGSA Architected Services – Grid Data Services

• Support data virtualization

• Provide mechanism for access to distributed resources

such as databases, files

46 Course: GCC Unit: 2; Session: 1 Grid Services


OGSA Architecture – OGSA Architected Services - Layer

47 Course: GCC Unit: 2; Session: 1 Grid Services


OGSA Architecture – Grid Applications Layer

• This layer comprise of applications that use the grid


architected services

48 Course: GCC Unit: 2; Session: 1 Grid Services


Conclusion

• Grid-Computing allows networked resources to be combined

and used

• Grid-Computing offers great benefit to an organization

• OGSA are comprehensive standards which governs grid-

computing

Course: GCC Unit: 2; Session: 1 Grid Services


Open Grid Services Infrastructure (OGSI)

• OGSI defines the mechanisms to create grid


services
• Introduces the notion of grid services and their
special properties particularly the global pointer
GSH (Grid Service Handle)

Course: GCC Unit: 2; Session: 1 Grid Services


Open Grid Services Infrastructure (OGSI)
 OGSI creates an extension model for WSDL called GWSDL (Grid WSDL).
The reason is:
 Interface inheritance
 Service Data (for expressing state information)
 Components:

 Lifecycle
 State management
 Service Groups
 Factory
 Notification
 Handle Map

51 Course: GCC Unit: 2; Session: 1 Grid Services


OGSI - 2001
• OGSA is the architecture, OGSI is the infrastructure.
• Grid service interface standard
• Methods allow access to Grid service
• As well as Grid service state (SDE) OGSI Registry

• Optional factory interface Grid Service Reference


(GSR)

• Naming and referencing of Grid services


Grid Service
Handle (GSH) Publish GSR
• Extends WSDL 1.1 (GWSDL)
• Handle resolver Service Consumer Service Provider

• Notifications Bind
Client Grid Service
Reply

Legend
program boundary request flow
module boundary Grid Service Reference reply flow

OGSI Grid service locator:


•Multiple GHSs + GSRs + interface description
Grid Services as seen by OGSI

• Connect to the grid service


• Ask the server to create an instance for you
• Get a unique global pointer to it
• Interact with the service

Course: GCC Unit: 2; Session: 1 Grid Services


OGSI Issues

• Confusion and Criticism from web services folks


• Modeling stateful resource with Web services
• Web service Resource Framework (WS-RF) 2004

Course: GCC Unit: 2; Session: 1 Grid Services


WSRF

• Stands for Web Services Resource Framework


• Improves on the concept of Web Services by
creating a separate view for the resource state.
• Simplifies WSDL and reduces message size and
complexity (XML gets heavy and complicated
fast)
• Modular (users decide which specification to use)

Course: GCC Unit: 2; Session: 1 Grid Services


WS-Resource

• Provides a means of expressing


the relationship between stateful
resources and web services
• The WS-Resource has an XML
resource property document
defined using XML schema.
• The requestor can determine the
WS-Resource type by retrieving
the portType
• Web service programming
Course: GCC Unit: 2; Session: 1 Grid Services

paradigm is used to interact with


Web Services and Grids - OGSA

• OGSI problems solved by WSRF

Grid GT1
GT2
OGS
Started I
far apart Have been
in apps converging WSRF
& tech
D L 2,
WS
D L , SD M
WS W
Web P W S-*
HTT

Course: GCC Unit: 2; Session: 1 Grid Services


Global Toolkit

• The Globus Toolkit is a software toolkit, developed


by The Globus Alliance, which can be used to
program grid-based applications.
• Globus Toolkit includes a resource monitoring and
discovery service, a job submission infrastructure,
a security infrastructure, and data management
services;

Course: GCC Unit: 2; Session: 1 Grid Services


WS-GRAM

• Globus Tookit 4 contains a web


service-based Grid Resource
Allocation and Management (GRAM)
component.
• WS-GRAM is a WSRF-based web
service used by computational
resources on the Teragrid to
remotely submit, monitor, and
cancel jobs.
• These jobs may be either be
interactive jobs which tend
Course: GCC Unit: 2; Session: 1 Grid Services
to
perform simple tasks which
Programming Grid Services (GT4)

• Basic steps involved in creating a grid service


• Create the interface using WSDL
• Specify the portTypes, messages and data
encoding
• Generate Stubs
• Add functionality
• Compile and Build the code using Globus
libraries
• Create a GAR (Grid Archive)
• Deploy it

Course: GCC Unit: 2; Session: 1 Grid Services


OGSA, WSRF & GT4

B. Sotomayor and L. Childers. Globus Toolkit 4,


Programming Java Services. 2006. The Morgan
Kaufmann Series in Networking.

Course: GCC Unit: 2; Session: 1 Grid Services


Data intensive grid service models
Applications in the grid are normally grouped into two categories
• Computation-intensive and Data intensive
• Data intensive applications deals with massive amounts of data. The
grid system must specially designed to discover, transfer and
manipulate the massive data sets.
• Transferring the massive data sets is a time consuming task.
• Data access method is also known as caching, which is often
applied to enhance data efficiency in a grid environment.
•By replicating the same data block and scattering them in multiple
regions in a grid, users can access the same data with locality of
references.
62 Course: GCC Unit: 2; Session: 1 Grid Services
Data intensive grid service models
• Replication strategies determine when and where to create a replica of the data.

• The strategies of replications can be classified into dynamic and static

Static method

• The locations and number of replicas are determined in advance and will not be modified.

• Replication operation require little overhead

• Static strategic cannot adapt to changes in demand, bandwidth and storage variability

• Optimization is required to determine the location and number of data replicas.

Dynamic strategies

• Dynamic strategies can adjust locations and number of data replicas according to change in conditions

• Frequent data moving operations can result in much more overhead the static strategies

• Optimization may be determined based on whether the data replica is being created, deleted or moved.

• The most common replication include preserving locality, minimizing update costs and maximizing profits .

63 Course: GCC Unit: 2; Session: 1 Grid Services


Grid data Access models

In general there are four access models for organizing a


data grid as listed here

1. Monadic method

2. Hierarchical model

3. Federation model

4. Hybrid model

64 Course: GCC Unit: 2; Session: 1 Grid Services


Monadic method

• This is a centralized data repository model.


All data is saved in central data repository.
• When users want to access some data they
have no submit request directly to the
central repository.
• No data is replicated for preserving data
locality.
• For a larger grid this model is not efficient
in terms of performance and reliability.
• Data replication is permitted in this model
only when fault tolerance is demanded.

65 Course: GCC Unit: 2; Session: 1 Grid Services


Hierarchical model

• It is suitable for building a large data grid


which has only one large data access directory
• Data may be transferred from the source to a
second level center. Then some data in the
regional center is transferred to the third level
centre.
• After being forwarded several times specific
data objects are accessed directly by users.
Higher level data center has a wider coverage
area.
• PKI security services are easier to implement
in this hierarchical data access model

66 Course: GCC Unit: 2; Session: 1 Grid Services


Federation model
• It is suited for designing a data
grid with multiple source of data
supplies.
• It is also known as a mesh model
• The data is shared the data and
items are owned and controlled
by their original owners.
• Only authenticated users are
authorized to request data from
any data source.
• This mesh model cost the most
when the number of grid
intuitions becomes very large

67 Course: GCC Unit: 2; Session: 1 Grid Services


Hybrid model

• This model combines the best


features of the hierarchical and
mesh models.
• Traditional data transfer technology
such as FTP applies for networks
with lower bandwidth.
• High bandwidth are exploited by
high speed data transfer tools such
as GridFTP developed with Globus
library.
• The cost of hybrid model can be
traded off between the two extreme
models of hierarchical and mesh-
connected grids.

68 Course: GCC Unit: 2; Session: 1 Grid Services


Parallel versus Striped Data Transfers

• Parallel data transfer opens multiple data streams for passing


subdivided segments of a file simultaneously. Although the speed of
each stream is same as in sequential streaming, the total time to
move data in all streams can be significantly reduced compared to
FTP transfer.
• Striped data transfer a data objects is partitioned into a number of
sections and each section is placed in an individual site in a data
grid. When a user requests this piece of data, a data stream is created
for each site in a data gird. When user requests this piece of data,
data stream is created for each site, and all the sections of data
objects ate transected simultaneously.

69 Course: GCC Unit: 2; Session: 1 Grid Services


References

1. Kai Hwang, Geoffery C. Fox and Jack J. Dongarra, “Distributed and Cloud Computing:

Clusters, Grids, Clouds and the Future of Internet”,

2. https://www.dcc.fc.up.pt/~ines/aulas/1213/CG/OGSA.ppt

3. http://www.computerworld.com/article/2552339/networking/open-grid-services-

architecture.html

4. http://searchsoa.techtarget.com/definition/Open-Grid-Services-Architecture

5. www.cs.umsl.edu/~sanjiv/classes/cs6740/presentation/OGSA.ppt

6. www.nesc.ac.uk/news/.../OpenGridServicesArchitectureApril20021.ppt

7. www.cse.buffalo.edu/~bina/cse486/spring2011/progtutorial_0.4.3.pdf

70 Course: GCC Unit: 2; Session: 1 Grid Services


Bibliografy

• Masoud Sadjadi’s Lecute Lecture on


Developing Grid Services on LA Grid
• Laukik Chitnis and Sanjay Ranka’s
Tutorial on Grid
• Onyeka Ezenwoye’s Lecture on Web
Services
• TeraGridForum wiki:
http://www.teragridforum.org/media
wiki/index.php?title=WS-Gram
• Python WSRF Programmers'
Course: GCC Unit: 2; Session: 1 Grid Services
Tutorial:
• end

Course: GCC Unit: 2; Session: 1 Grid Services

You might also like