Upload
edward-hall
View
220
Download
2
Embed Size (px)
Citation preview
®
IBM Software Group
© 2009 IBM Corporation
Updated April 19, 2023
WebSphere Enterprise Service Bus 7.0.0 WebSphere Integration Developer 7.0.0
Mediation Policy Extensions
Brian Hulse: WESB Development
IBM Software Group
2
© 2009 IBM Corporation
Mode1: Module Scope
Module
SCA Module Definition
Policy Resolution Primitive
Delivered in 6.2
IBM Software Group
3
© 2009 IBM Corporation
Extends 6.2 function to allow for:Attachment of Mediation Policies at Target Service scope
Service
Port
PortType
Binding
BindingOperation
PortTypeOperation
The “more particular” scope overrides the “less particular” Value for Assertion on Operation would override value for assertion on Service, for
example
Intersection of Module and Target Service scopes Both Module and Target Services policies have to match
Mediation Policy 7.0
Operation
Endpoint
Service
IBM Software Group
4
© 2009 IBM Corporation
Policy Resolution Primitive
Mode 2: Target Service Scope
PortType
Binding
Port
Service
PortTypeOperation
BindingOperation
WSDL definitionfor target service
MediationPolicies
IBM Software Group
5
© 2009 IBM Corporation
PortType
Binding
Port
Service
MediationPolicies
Mode 3:Intersection
Module
Intersected mediationpolicies
Policy Resolution Primitive
PortTypeOperation
BindingOperation
WSDL definitionfor target service
IBM Software Group
6
© 2009 IBM Corporation
Selecting the Target Service …
If the Target Service mode is selected for the Policy Resolution Primitive, an Endpoint Lookup Primitive MUST be used prior to the PRP. This:
Selects the endpoint for the PRP (and presumably the dynamic endpoint for the flow)
Loads the TargetAddress with repositoryMetadata
This is actually the bsrURI of the port, which is unique for the endpoint selected. This is needed to avoid ambiguity.
IBM Software Group
7
© 2009 IBM Corporation
Selecting the Target Service Operation …
In addition, if Operation level scope is required. The Operation field of the SMO must be populated with the name of the Operation the PRP will extract policy attachments from.
Obviously, if not set, no policy attachments for operation level will be found.
IBM Software Group
8
© 2009 IBM Corporation
The case for Bindings … WSRR prior to 6.2 did not support Binding or BindingOperation, so if the default connection is used when creating the WSRR definition in the admin console, no policy attachments on these levels will be found. The example below will find these …
IBM Software Group
9
© 2009 IBM Corporation
The case for Bindings … However, these will only apply if the user has used the WSRR
console directly
Using the supplied Business Space widgets there is no way of creating policy attachments at:
Binding BindingOperation
Any policy attachments at these levels will appear as Endpoint level policies
IBM Software Group
10
© 2009 IBM Corporation
Peer and hierarchical merge … The processing for multiple policy attachments follows the rules
set out in the WS-PolicyAttachment specification.
service
portType port binding
bindingOperation portTypeOperation
Peer merge
Peer merge
Peer merge
Hierarchical merge
lower precedence
higher precedence
NOTE: We do warn customers to avoid this level of complexity as it becomes difficult to predict behaviour.
IBM Software Group
11
© 2009 IBM Corporation
Successful Merge
If Operation level policy has propB = BBB and Service level policy has propB = YYY
Operation is preferred
So propB = BBB
Unsuccessful Merge
Port level policy has propA = AAA and PortType level policy has propA = XXX
Neither is preferred, so they cannot be combined
The policyError terminal will be fired
IBM Software Group
12
© 2009 IBM Corporation
Evolution of policy administration
Mediation Policy was introduced in WESB 6.2
Policies, Policy Attachments could only be created using the WSRR console directly.
This was prone to error as many of the WESB concepts were on very disparate screens
Business Space widgets in 7.0 allow for:Creation of new mediation policiesCreation of policy attachments at
Module scope Target Service scope
Definition of gate conditions
… in one place!
IBM Software Group
13
© 2009 IBM Corporation
Creating a Module Administration space …
IBM Software Group
14
© 2009 IBM Corporation
Module Browser …
•Solution Administration template gives two widgets Module Browser Mediation Policy Administration
IBM Software Group
15
© 2009 IBM Corporation
New Policy Attachment …
Groups (Domains) available for module
IBM Software Group
16
© 2009 IBM Corporation
New Policy …
IBM Software Group
17
© 2009 IBM Corporation
Creating a Service Administration space …
IBM Software Group
18
© 2009 IBM Corporation
Service Browser …
•Service Administration template gives two widgets Service Browser Mediation Policy Administration
IBM Software Group
19
© 2009 IBM Corporation
Service Browser …
Service
Operations
Endpoints
IBM Software Group
20
© 2009 IBM Corporation
New Policy Attachment (Services) …
All Groups (Domains) for all modules
IBM Software Group
21
© 2009 IBM Corporation
WSDL scope points … WS-Policy allows for many attachment points in WSDL
Our widgets aggregate some of these attachment points for simplicity
Endpoint scope is an aggregation of: Port PortType Binding
Operation scope is an aggregation of: BindingOperation PortTypeOperation
Creating a policy attachment at Endpoint scope is really PortType scope
Creating a policy attachment at Operation scope is really PortTypeOperation scope
IBM Software Group
22
© 2009 IBM Corporation
Policy Servlet … Business Space widgets talk REST to the Policy Servlet
The Policy Servlet talks to WSRR via its HTTP interface
Policy Attachments
Policies
WSRR WPSPolicyServlet
BusinessSpace
REST interface
Modules
WSDLs
IBM Software Group
23
© 2009 IBM Corporation
Service Gateway: Service Level Policy http://www.ibm.com/developerworks/websphere/library/techarticles/1001_hulse/
1001_hulse.html
In Service Gateway /headers/SMOHeader/Action is populated with soapAction
IBM Software Group
24
© 2009 IBM Corporation
Service Gateway: Operation Level Policy