Title: ServiceOriented Architecture
1Service-Oriented Architecture
- Chapter 17
- Fundamental WS- Extensions
2WS-Addressing language basics
- WS-Addressing is a core WS- extension providing
features that can be used intrinsically or
alongside features offered by other WS-
specifications. - The EndpointReference element
- This element is used by the From, ReplyTo, and
FaultTo elements described in the Message
information header elements section.
3WS-Addressing language basics
- WS-Addressing endpoint reference elements.
4WS-Addressing language basics
- Message information header elements
- This collection of elements can be used in
various ways to assemble metadata-rich SOAP
header blocks. - WS-Addressing message information header elements
5WS-Addressing language basics
- WS-Addressing message information header elements
6WS-Addressing language basics
- WS-Addressing reusability
- Established generic set of extensions useful to
custom service-oriented solutions. - Also reusable by other WS- specifications
7WS-Addressing Summary
- WS-Addressing provides a collection of message
header elements that can supplement a message
with various (mostly routing-related) meta
information. - The WS-Addressing specification defines a set of
reusable extensions that are becoming
intrinsically commonplace among other
WS-specifications. - It is worth remembering that some of the message
information header elements established by
WS-Addressing are of type EndpointReference and
can therefore be contain a variety of endpoint
metadata.
8WS-ReliableMessaging language basics
- WS-ReliableMessaging introduces critical quality
of service features for the guaranteed delivery
or failure notification of SOAP messages. - It also positions itself as a fundamental-
extension, as show in Figure 17.2 - Key WS-ReliableMessaging language elements
- Sequence element
- MessageNumber element
- LastMessage element
- SequenceAcknowledgement element
- AcknowledgementRange element
- Nack element
- AckRequested element
9WS-ReliableMessaging language basics
10WS-ReliableMessaging language basics
- The Sequence, MessageNumber, and LastMessage
elements - Sequence construct resides in the SOAP message
header to represent the location of the current
message. - In relation to the overall sequence of messages
within which it is being delivered. - Sequence relies on a set of child elements.
- Identifier element is used to contain an ID value
associated with the sequence itself
11WS-ReliableMessaging language basics
- MessageNumber element contains a number that is
the position of the message within the overall
sequence order. - LastMessage element can be added to the Sequence
construct to communicate the fact that the
current message is the final message of the
sequence.
12WS-ReliableMessaging language basics
- The SequenceAcknowledgement and
AcknowledgementRange elements - SequenceAcknowledgement is issued by the
recipient service upon the arrival of one or more
messages with a sequence. - The SequenceAcknowledgement header construct to
communicate that the original delivery was
successful. - AcknowledgementRange element contains the Upper
and Lower attributes that indicate a range of
messages that were received. - The Range is based on the MessageNumber values of
the message. - One AcknowledgementRange element communicates
each consecutive set of messages received. - Sequence construct resides in the SOAP message
header to represent the location of the current
message.
13WS-ReliableMessaging language basics
- The Nack element
- Communicates the delivery failure of a message.
- Its show which messages were not received.
- The AckRequested element
- RM source service can request that the RM
destination send out a sequence acknowledgement
message on demand by using the AckRequested
header construct.
14WS-ReliableMessaging language basics
- Other WS-ReliableMessaging elements
- Additional WS-ReliableMessaging elements
15WS-ReliableMessaging Summary
- WS-ReliableMessaging introduces a set of elements
that govern the processing of message sequences
and subsequent delivery acknowledgments. - WS-ReliableMessaging establishes the concept of a
sequence, as implemented via the Sequence
construct. This represents a group of messages to
which additional delivery rules can be applied. - WS-ReliableMessaging further introduces the
concept of acknowledgements, as established by
the SequenceAckowledgement and Nack elements,
which provide an inherent mechanism for a
guaranteed notification of successful and failed
deliveries.
16WS-Policy language basics
- The WS-Policy framework establishes a means of
expressing service metadata beyond the WSDL
definition - The WS-Policy framework is comprised of the
following three specifications - WS-Policy
- WS-PolicyAssertions
- WS-PolicyAttachments
17WS-Policy Relation to other WS- Specifications
18Policy Element
- Establishes the root construct to contain the
various policy assertions that comprise the
policy - The WS-PolicyAssertions specification supplies
the following set of common, predefined
assertions elements - TextEncoding Dictates the use of a specific
text encoding format
19Policy Element cont
- Language Expresses the requirement or
preference for a particular language - SpecVersion Communicates the need for a
specific version of a specification - MessagePredicate Indicates message processing
rules expressed using Xpath statements
20ExactlyOne Element
- Surrounds multiple policy assertions and
indicates that there is a choice between them,
but that one must be chosen
21All Element
- States that all of the policy assertions within
the construct must be met
22Usage Attribute
23Preference Attribute
- Used to rank policy assertions in order of
preference - Assigned an integer value
- Higher value means a more preferred assertion
- Default value is 0
24PolicyReference Element
- A way to simply link an element with one or more
policies - Contains a URI attribute that points to one
policy document or a specific policy assertion
within the document - Policy documents are merged at runtime when
multiple PolicyReference elements are used within
the same element
25PolicyURIs Attribute
- Can be used to link to one or more policy
documents - Added to an element and can be assigned multiple
policy locations - Policies are merged at runtime
- Example
- ltEmployee wspPolicyURIshttp//www.xmltc.com/
tls/policy1.xmlEmp1 - http//www.xmltc.com/tls/policy2.xmlEmp2 /gt
26PolicyAttachment Element
- Associates a policy with a subject
- The child AppliesTo construct is positioned as
the parent of the subject elements - The PolicyReference element the follows the
AppliesTo construct to identify the policy
assertions that will be used
27Additional Types of Policy Assertions
- Policy assertions can be incorporated into WSDL
definitions through the use of a special set of
policy subjects that target specific parts of the
definition structure - A separate UsingPolicy element is provided for
use as a WSDL extension - WS-ReliableMessaging defines and relies on
WS-Policy assertions to enforce some of its
delivery and acknowledgement rules
28Additional Types cont
- WS-Policy assertions can be created to
communicate that a Web service is capable of
participating in a business activity or an atomic
transaction - A policy assertion can be designed to express a
services processing requirements in relation to
other WS- specifications - WS-Policy assertions commonly are utilized within
the WS-Security framework to express security
requirements
29WS-MetadataExchange Language Basics
- Provides a standardized means by which service
description documents can be requested and
supplied. - Supports interoperability and quality of service
(QoS) - Standardized metadata requests are
- GetMetadata
- Get
30WS-MetadataExchange Relation to other WS-
Specifications
31GetMetadata Element
- Placed in the Body area of a SOAP message
- Can be turned into a construct that hosts child
Dialect and Identifier elements
32Dialect Element
- Specifies the type and version of the metadata
specification requested - Guarantees that the metadata returned to the
service requesting it will be understood
33Identifier Element
- Narrows the criteria by asking for a specific
part of the metadata
34Metadata, MetadataSection, and MetadataReference
Elements
- Used to organize the content of the message sent
in response to a GetMetadata request - Metadata
- construct resides in the SOAP message Body area
- MetadataSection
- constructs that each represent a part of the
returned metadata - Holds the contents of the metadata document
returned
35Metadata, MetadataSection, and MetadataReference
Elements
- MetadataReference
- Holds the pointer to the document if that is all
that is returned
36Get Message
- Used to explicitly request one of the documents
from the location provided in the
MetadataReference contstruct
37WS-Security Language Basics
- Provides extensions that can be used to implement
message-level security measures - Designed to work with any of the WS-
specifications talked about so far - Comprised of numerous specifications, many in
different stages of acceptance and maturation
38WS-Security Relation to other WS- Specifications
39Security Element
- Represents the fundamental header block provided
by WS-Security - Can have a variety of child elements
- XML-Encryption
- XML-Signature
- WS-Security specification itself
- Can be outfitted with actor attributes that
correspond to SOAP actor roles
40UsernameToken, Username, and Password Elements
- Can be used to host token information for
authentication and authorization purposes - Custom elements can be added, but the Username
and Password child elements are typical children
to this construct
41BinarySecurityToken Element
- Tokens stored as binary data
- Example
- Certificates
42SecurityTokenReference Element
- Allows a pointer to be provided to a token that
exists outside of the SOAP message document
43EncryptedData Element
- Parent construct that hosts the encrypted portion
of an XML document - The Type attribute indicates what is included in
the encrypted content
44CipherData, CipherValue, and CipherReference
Elements
- CipherData construct is required and must contain
either a CipherValue element hosting the
characters representing the encrypted text or a
CipherReference element that provides a pointer
to the encrypted values
45XML-Signature Elements
46XML-Signature Elements