0%

Book Description

Design and build Service-Oriented Architecture Solutions with the Oracle SOA Suite 10gR3

  • A hands-on guide to using and applying the Oracle SOA Suite in the delivery of real-world SOA applications.

  • Detailed coverage of the Oracle Service Bus, BPEL Process Manager, Web Service Manager, Rules, Human Workflow, and Business Activity Monitoring.

  • Master the best way to combine / use each of these different components in the implementation of a SOA solution.

  • llustrates key techniques and best practices using a working example of an online auction site (oBay).

In Detail

We are moving towards a standards-based Service-Oriented Architecture (SOA), where IT infrastructure is continuously adapted to keep up with the pace of business change. Oracle is at the forefront of this vision, with the Oracle SOA Suite providing the most comprehensive, proven, and integrated tool kit for building SOA based applications.

Developers and Architects using the Oracle SOA Suite, whether working on integration projects, building composite applications, or specializing in implementations of Oracle Applications, need a hands-on guide on how best to harness and apply this technology.

This book will guide you on using and applying the Oracle SOA Suite to solve real-world problems, enabling you to quickly learn and master the technology and its applications.

The initial section of the book is aimed at providing you with a detailed hands-on tutorial to each of the core components that make up the Oracle SOA Suite; namely the Oracle Service Bus, BPEL Process Manager, Human Workflow, Business Rules, and Business Activity Monitoring. Once you are familiar with the various pieces of the SOA Suite and what they do, the next question will typically be: "What is the best way to combine / use all of these different components to implement a real-world SOA solution?"

Answering this question is the goal of the next section. Using a working example of an online auction site (oBay), it leads you through key SOA design considerations in implementing a robust solution that is designed for change. Though the examples in the book are based on Oracle SOA Suite 10.1.3.4 the book will still be extremely useful for anyone using 11g.

The final section addresses non-functional considerations and covers the packaging, deployment, and testing of SOA applications; it then details how to use Web Service Manager to secure and administer SOA applications.

Table of Contents

  1. Oracle SOA Suite Developer's Guide
  2. Credits
  3. Foreword
  4. About the Authors
  5. About the Reviewers
  6. Preface
    1. What this book covers
      1. Section 1: Getting started
      2. Section 2: Putting it all together
      3. Section 3: Other considerations
    2. Who is this book for
    3. Conventions
    4. Reader feedback
    5. Customer support
      1. Downloading the example code for the book
      2. Errata
      3. Piracy
      4. Questions
  7. 1. Introduction to Oracle SOA Suite
    1. Service-oriented architecture in short
      1. Service
      2. Orientation
      3. Architecture
    2. Why SOA is different
      1. Terminology
      2. Inter-operability
      3. Extension and evolution
      4. Reuse in place
    3. SOA Suite components
      1. Services and adapters
      2. ESB — service abstraction layer
        1. Oracle Service Bus and Oracle ESB
          1. Oracle Service Bus and Oracle ESB
      3. Service orchestration — BPEL Process Manager
      4. Rules
      5. Security and monitoring — OWSM
      6. Active monitoring — BAM
      7. Business to business — B2B
      8. Complex Event Processing — CEP
    4. SOA Suite architecture
      1. Top level
      2. Component view
      3. Implementation view
      4. A recursive example
    5. JDeveloper
    6. Other components
      1. Service repository and registry
      2. BPA Suite
      3. BPM Suite
      4. Portals and WebCenter
      5. Enterprise manager SOA management pack
    7. Summary
  8. 2. Writing Your First Service
    1. Installing SOA Suite
    2. Writing our first BPEL process
      1. Creating an application
      2. Creating a BPEL project
        1. Assigning values to variables
      3. Deploying the process
      4. Testing the BPEL process
    3. Writing our first proxy service
      1. Writing the Echo proxy service
      2. Creating a change session
      3. Creating a project
        1. Creating project folders
      4. Creating service WSDL
        1. Importing a WSDL
      5. Creating our business service
      6. Creating our proxy service
        1. Creating message flow
        2. Activating the Echo proxy service
        3. Testing our proxy service
    4. Summary
  9. 3. Service Enabling Existing Systems
    1. Types of systems
      1. Web service interfaces
      2. Technology interfaces
      3. Application interfaces
    2. Java Connector Architecture
    3. Creating services from files
      1. A payroll use case
      2. Reading a payroll file
        1. Starting the wizard
        2. Naming the service
        3. Identifying the operation
        4. Defining the file location
        5. Selecting specific files
        6. Detecting that the file is available
        7. Message format
          1. Defining a native format schema
          2. Using a sample file
          3. Record structure
          4. Choosing a root element
          5. Message delimiters
          6. Record type names
          7. Field properties
          8. Verifying the result
        8. Finishing the wizards
      3. Throttling the file and FTP adapter
        1. Creating a dummy message type
        2. Adding an output message to the read operation
        3. Using the modified interface
      4. Writing a payroll file
        1. Selecting the FTP connection
        2. Choosing the operation
        3. Selecting the file destination
        4. Completing the FTP file writer service
      5. Moving, copying, and deleting files
        1. Generate an adapter
        2. Modify the port type
        3. Modify the binding
        4. Add additional header properties
      6. Adapter headers
      7. Testing the file adapters
    4. Creating services from databases
      1. Writing to a database
        1. Selecting the database schema
        2. Identifying the operation type
        3. Identifying tables to be operated on
        4. Identifying the relationship between tables
        5. Under the covers
    5. Summary
  10. 4. Loosely Coupling Services
    1. Coupling
      1. Number of input data items
      2. Number of output data items
      3. Dependencies on other services
      4. Dependencies of other services on this service
      5. Use of shared global data
      6. Temporal dependencies
    2. Reducing coupling in stateful services
    3. Oracle Service Bus design tools
      1. Oracle workshop for WebLogic
      2. Oracle Service Bus Console
    4. Service Bus overview
      1. Service Bus message flow
    5. Virtualizing service endpoints
      1. Moving service location
      2. Selecting a service to call
    6. Virtualizing service interfaces
      1. Physical versus logical interfaces
      2. Mapping service interfaces
      3. Applying canonical form in the service bus
        1. An important optimization
    7. Summary
  11. 5. Using BPEL to Build Composite Services and Business Processes
    1. Basic structure of a BPEL process
      1. Core BPEL process
        1. Variables
      2. Partner Links
      3. Messaging activities
        1. Synchronous messaging
        2. Asynchronous messaging
          1. One way messaging
    2. A simple composite service
      1. Creating our Stock Quote service
        1. Import StockService schema
      2. Calling the external web services
        1. Calling the web service
        2. Assigning values to variables
        3. Testing the process
        4. Calling the exchange rate web service
        5. Assigning constant values to variables
        6. Using the Expression builder
      3. Asynchronous service
        1. Using the Wait activity
      4. Improving the stock trade service
        1. Creating the while loop
        2. Checking the price
        3. Using the Switch activity
    3. Summary
  12. 6. Adding in Human Workflow
    1. Workflow overview
    2. Leave approval workflow
      1. Creating our workflow process
        1. Defining the workflow task
        2. Specifying task parameters
          1. Specifying task assignment and routing policy
          2. Initializing the workflow parameter
        3. Creating the user interface to process the task
        4. Running the workflow process
    3. Processing tasks with the worklist application
    4. Improving the workflow
      1. Dynamic task assignment
        1. Assigning tasks to multiple users or groups
      2. Cancelling or modifying a task
        1. Withdrawing a task
        2. Modifying a task
        3. Difference between task owner and initiator
      3. Requesting additional information about a task
    5. Managing the assignment of tasks
      1. Reassigning reportee tasks
        1. Reassigning your own task
        2. Delegating tasks
        3. Escalating tasks
      2. Using rules to automatically manage tasks
        1. Setting up a sample rule
    6. Summary
  13. 7. Using Business Rules to Define Decision Points
    1. Business Rule concepts
      1. Leave approval rule
    2. Using the Rule Author
      1. Creating a Rule Repository
      2. Creating a dictionary
      3. Defining facts
        1. Creating XML Facts
        2. Using aliases
        3. Hiding facts and properties
        4. Saving the rule dictionary
      4. Creating a rule set
        1. Adding a rule to our rule set
          1. Creating the If clause
          2. Choosing the pattern
        2. Defining the test for the pattern
          1. Creating the Then clause
    3. Creating a Decision Service
      1. Creating a Rule Engine Connection
        1. Using a file based repository
        2. Using a WebDAV repository
      2. Creating a Decision Service
      3. Adding a Decide activity
        1. Assigning facts
    4. Using functions
      1. Importing Java classes as facts
      2. Creating a function
      3. Invoking a function from within a rule
    5. Summary
  14. 8. Building Real-time Dashboards
    1. How BAM differs from traditional business intelligence
    2. Oracle BAM scenarios
    3. BAM architecture
      1. Logical view
      2. Physical view
        1. Capture
        2. Store
        3. Process
        4. Deliver
      3. BAM platform anomaly
      4. User interface
    4. Monitoring process state
      1. Defining data objects
        1. A digression on populating data object fields
      2. Instrumenting BPEL
      3. Testing the events
      4. Creating a simple dashboard
    5. Monitoring process status
    6. Monitoring KPIs
    7. Summary
  15. 9. oBay Introduction
    1. oBay requirements
      1. User registration
        1. User login
      2. Selling items
        1. List a new item
        2. Cancel listing
        3. Completing the sale
        4. View account
      3. Buying items
        1. Search for items
        2. Bidding on items
    2. Defining our blueprint for SOA
      1. Architecture goals
      2. Typical SOA architecture
        1. Application services layer
        2. Virtual services layer
        3. Business services layer
          1. Functional type
          2. Service consumer
        4. Business process
        5. User Interface layer
    3. One additional layer
      1. Where the SOA Suite fits
        1. Where the SOA Suite fits
    4. oBay high-level architecture
      1. oBay Application services
        1. Workflow services
        2. External web services
        3. oBay developed services
      2. oBay internal virtual services
      3. oBay business services
        1. oBay business processes
      4. oBay user interface
    5. Downloading and installing oBay application
    6. Summary
  16. 10. Designing the Service Contract
    1. Using XML Schema to define business objects
      1. Modelling data in XML
        1. Data decomposition
        2. Data hierarchy
        3. Data semantics
        4. Use attributes for metadata
      2. Schema guidelines
        1. Element naming
          1. Name length
          2. Compound names
          3. Naming standards
        2. Namespace considerations
          1. Always specify a target namespace
          2. Default namespace
          3. Qualified or unqualified element names
          4. Qualified or unqualified attributes
          5. Namespace prefixes
          6. Global versus local
          7. Elements versus types
      3. Partitioning the canonical model
        1. Single namespace
        2. Multiple namespaces
          1. Separate common objects into their own namespace
        3. Chameleon namespaces
          1. Disadvantages of chameleon namespace
    2. Using WSDL to define business services
      1. Use document (literal) wrapped
      2. Building your abstract WSDL document
        1. WSDL namespace
        2. Defining the 'wrapper' elements
          1. Importing canonical model
        3. Defining the 'message' elements
        4. Defining the 'portType' element
    3. Using XML Schema and the WSDL within BPEL PM
      1. Sharing XML Schemas across BPEL processes
        1. Deploying schemas to the BPEL server
        2. Importing schemas
        3. Updating the schema URL
      2. Importing the WSDL document into BPEL PM
        1. Adding the PartnerLink definition to the abstract WSDL
      3. Sharing XML Schemas in the service bus
      4. Importing the WSDL document into the service bus
    4. Strategies for managing change
      1. Major and minor versions
        1. Service implementation versioning
      2. Schema versioning
        1. Change schema location
        2. Update schema version attribute
        3. Resist changing the schema namespace
      3. WSDL versioning
        1. Incorporating changes to the canonical model
        2. Changes to the physical contract
        3. Updating the service endpoint
        4. Managing the service lifecycle
    5. Summary
  17. 11. Building Business Services
    1. Build versus reuse
      1. Adapters and web service wrappers
        1. Adapters
        2. Service wrappers
    2. Reusing existing functionality directly
      1. Exposing a PL/SQL stored procedure as a service
        1. Launching the PL/SQL web service wizard
        2. Choosing the level of Java Enterprise Edition support
        3. Selecting a database connection and defining service bindings
        4. Determine message style
        5. Select stored procedures and functions to expose
    3. Modifying existing functionality using service bus
      1. Converting an existing service to canonical form
        1. Create a new service interface
        2. Adding the non-canonical service
        3. More complex conversions
      2. Exposing a Java class as a service
        1. Wrapping the Java code
        2. Launching the Web Service wizard
        3. Select deployment platform
        4. Select service name
        5. Select message format
        6. Provide custom serializers
        7. Mapping
        8. Select methods
    4. Creating services from scratch
      1. Creating a Java service from a WSDL
        1. Starting the wizard
        2. Choosing the WSDL
        3. Choosing the mapping options
        4. The generated Java
    5. Summary
  18. 12. Building Validation into Services
    1. Using XML Schema validation
      1. Strongly typed services
      2. Loosely typed services
      3. Combined approach
      4. Using schema validation within BPEL PM
        1. Validation of inbound documents
        2. Validation of outbound documents
        3. Validation between BPEL processes
          1. Validation for synchronous interactions
          2. Validation for asynchronous interactions
        4. Setting validateXML for a BPEL domain
        5. Setting validateXML for a PartnerLink
      5. Using schema validation within the service bus
        1. Validation of inbound documents
        2. Validation of outbound documents
    2. Using Schematron for validation
      1. Overview of Schematron
        1. Assertions
        2. Rules
        3. Patterns
        4. Namespaces
        5. Schema
      2. Intermediate validation
        1. Cross field validation
          1. Using XPath predicates in rules
          2. Using XPath 2.0 functions
        2. Date validation
        3. Element present
      3. Using Schematron within BPEL PM
        1. Creating a Partner Link for the Validation Service
        2. Creating a Schematron file
        3. Invoking the validate operation
          1. Assigning the instanceFile
          2. Assigning the ruleFile
        4. Sharing a Schematron between processes
      4. Using Schematron with the service bus
    3. Putting validation in the underlying service
      1. Using Business Rules for validation
      2. Coding in validation
      3. Returning validation failures in synchronous services
        1. Defining faults
        2. Custom fault codes
        3. Validation failures in asynchronous services
    4. Layered validation considerations
      1. Dangers of over validation
      2. Dangers of under validation
      3. Negative coupling of validation
    5. Summary
  19. 13. Error Handling
    1. Business faults
      1. Defining faults in synchronous services
      2. Defining faults in asynchronous services
    2. Handling business faults in BPEL
      1. Catching faults
        1. Adding a catch branch
        2. Throwing faults
      2. Compensation
        1. Defining compensation
        2. Triggering a compensation handler
        3. Adding a compensate activity
      3. Returning faults
        1. Asynchronous considerations
    3. Using the fault management framework
      1. Defining a fault policy
        1. Defining fault policy conditions
          1. Specifying the <faultName>
          2. Specifying the <condition>
        2. Defining fault policy actions
          1. Retry action
          2. Human intervention action
          3. Re-throw action
          4. Abort action
          5. Replay scope action
          6. Java action
      2. Binding fault policies
        1. Binding fault polices at the process level
          1. Defining bindings on the process
          2. Defining bindings on the PartnerLink
        2. Binding fault policies at the domain level
        3. Binding resolution
      3. Human intervention in BPEL Console
        1. Change the input variable contents and retry
        2. Set the output variable and continue
    4. Handling faults within the service bus
      1. Handling faults in synchronous proxy services
        1. Raising an error
        2. Defining an error handler
          1. Adding a route error handler
          2. Checking the type of SOAP Faults
        3. Getting the qualified fault name
          1. Creating a SOAP Fault
        4. Handling unexpected faults
        5. Returning a SOAP Fault
        6. Adding a Service Error Handler
        7. Handling permanent faults
          1. Generating alerts
          2. Enabling alerts
        8. Handling transient faults
          1. Retrying non-responsive business service
      2. Handling faults in one-way proxy services
    5. Summary
  20. 14. Message Interaction Patterns
    1. Message routing
      1. WS-Addressing
        1. Request message with WS-Addressing
        2. Response message with WS-Addressing
        3. Additional message exchanges
    2. Using BPEL correlation sets
      1. Using correlation sets for multiple process interactions
        1. Defining a correlation set property
        2. Defining correlation set
        3. Using correlation sets
          1. Initializing the correlation set
        4. Defining property aliases
    3. Message aggregation
      1. Message routing
        1. Correlating the callback
        2. Specifying the reply to address
      2. Creating a proxy process
        1. Using the pick activity
        2. Defining the correlation sets
      3. Completing the aggregation
    4. Scheduling services
      1. Defining the schedule file
      2. Using FlowN
        1. Accessing branch specific data in FlowN
      3. Dynamic Partner Links
        1. Define common interface
        2. Define Job Partner Link
        3. Create endpoint reference
        4. Update Endpoint
      4. Re-cycling the scheduling file
    5. Summary
  21. 15. Workflow Patterns
    1. Managing multiple participants in a workflow
      1. Using multiple assignment and routing policies
        1. Determining the outcome by a group vote
          1. Assigning participants
          2. Skipping the second step
          3. Sharing attachments and comments
          4. Deciding on the outcome
      2. Using multiple Human Tasks
        1. Linking individual Human Tasks
    2. Using the workflow API
      1. Defining the order fulfillment Human Task
        1. Specifying task parameters
        2. Specifying the routing policy
        3. Notification settings
      2. Querying task instances
        1. Defining a Partner Link for the Task Query Service
          1. Modifying TaskQueryServiceInterface.wsdl
          2. Modifying TaskQueryService.wsdl
          3. Creating the Task Query Service PartnerLink
        2. User authentication
          1. Create credential element
        3. Querying tasks
          1. Specifying the Display Column List
        4. Flex fields
        5. Populating Flex Fields
        6. Accessing Flex fields
          1. Specifying the query predicate
          2. Using Flex fields in the query predicate
          3. Ordering the data
      3. Getting task details
      4. Updating a task instance
        1. Defining a PartnerLink for the Task Service
        2. Using the updateTask operation
          1. Updating the task payload
          2. Updating the task Flex fields
          3. Updating the task outcome
    3. Summary
  22. 16. Using Business Rules to Implement Services
    1. How the rule engine works
      1. Asserting facts
      2. Executing the ruleset
        1. Rule activation
        2. Rule firing
      3. Retrieve result
      4. Session management
      5. Debugging a ruleset
        1. Using DM.println to add additional logging
    2. Using business rules to implement an auction
      1. Defining our XML Facts
      2. Defining the decision service
    3. Using a global variable to reference the result set
      1. Defining a global variable
      2. Defining a rule to initialize a global variable
    4. Writing our auction rules
      1. Evaluating facts in date order
        1. Checking for non-existent fact
        2. Using Calendar functionality
        3. Updating the bid status
      2. Using inference
        1. Processing the next valid bid
      3. Using functions to manipulate XML Facts
        1. Asserting a winning bid
        2. Retracting a losing bid
        3. Rules to process a new winning bid
        4. Validating the next bid
        5. Rule to process a losing bid
          1. Capping the winning bid amount
      4. Complete ruleset
    5. Performance considerations
      1. Managing state within the BPEL process
        1. Managing state within the BPEL process
          1. Using functions to control the assertion of facts
    6. Summary
  23. 17. The Importance of Bindings
    1. The web services stack
      1. Logical view of web services stack
      2. Physical view of web services stack
    2. Understanding Web Service Description Language (WSDL)
      1. How to read WSDL
        1. <definitions>
        2. <types>
        3. <message>
        4. <portType>
        5. <binding>
        6. <service>
    3. The case for different bindings
      1. Connectivity
      2. Transactionality
      3. Performance
    4. JCA bindings
    5. Java bindings
      1. Creating a Java binding
    6. Service bus bindings
    7. Summary
  24. 18. Packaging and Deployment
    1. The need for packaging
      1. Problems with moving between environments
      2. Types of interface
        1. Web interfaces
        2. Command line interfaces
    2. SOA Suite packaging
      1. Oracle Service Bus
      2. Oracle BPEL Process Manager
        1. Deploying a BPEL process using the BPEL Console
        2. Deploying a BPEL process using 'ant'
        3. Enabling web service endpoint and WSDL location alteration
        4. Enabling adapter configuration
        5. XML Schema locations
        6. XSL imports
        7. BPEL deployment framework
          1. Creating a deployment plan template
          2. Creating a deployment plan
          3. Attaching a deployment plan to a BPEL suitcase
          4. Modifying ant to use deployment plan
      3. Oracle Web Services Manager (OWSM)
      4. Oracle rules
      5. Business activity monitoring
        1. Commands
        2. Selecting items
        3. Using iCommand
    3. Deployment architectures
      1. SOA Suite deployment architectures
        1. Using an external web server or load balancer
          1. BPEL Process Manager specifics
      2. Web services manager
        1. Console and monitor
      3. Oracle Service Bus
      4. Business activity monitoring
      5. Local hostnames
    4. Summary
  25. 19. Testing Composite Applications
    1. SOA Suite testing model
    2. One-off testing
      1. Testing BPEL processes
      2. Testing the service bus
    3. Automated testing
      1. The BPEL test framework
        1. BPEL test suites
        2. Data validation
        3. Deploying the test suite
        4. Running the test suites
        5. Partner link handling in test cases
        6. Simulation of process to process interactions
        7. Baseline scripts
    4. Regression testing
    5. System testing
    6. Composite testing
    7. Component testing
    8. Unit testing
    9. Performance testing
    10. User interface testing
    11. Summary
  26. 20. Defining Security and Management Policies
    1. Security and management challenges in the SOA environment
      1. Evolution of security and management
      2. Added complications of SOA environment
        1. Security impacts of SOA
        2. Management and monitoring impacts of SOA
    2. Securing services
      1. Security outside the SOA Suite
        1. Network security
        2. Preventing message interception
        3. Restricting access to services
      2. Declarative security versus explicit security
        1. Security as a facet
        2. Security as a service
      3. Web Services Manager model
      4. Policies
      5. Agents and gateways
        1. Distinctive benefits of gateways and agents
          1. Benefits of gateways
          2. Drawbacks of gateways
          3. Benefits of agents
          4. Drawbacks of agents
      6. Service bus model
    3. Creating gateways and agents
      1. Creating a gateway
        1. Registering gateway services
      2. Creating an agent
      3. Enabling agent services
    4. Defining policies
      1. Creating a new policy template to perform basic authentication
        1. Creating the template
        2. Extracting Credentials
        3. Authenticating a user
        4. Authorizing a user
        5. Saving the pipeline template
      2. Creating a new policy
        1. Creating an agent policy
        2. Creating a gateway policy
      3. Applying a policy through Service Bus Console
        1. Service accounts
        2. Using a service account
        3. Managing service bus user accounts
        4. Service bus roles
        5. Using a role to protect a proxy service
      4. Final thoughts on security
    5. Monitoring services
      1. Monitoring overall service statistics in OWSM
      2. Defining a Service Level Agreement in OWSM
      3. Other monitoring and measuring features in OWSM
      4. Monitoring in service bus
        1. Creating an Alert Destination
        2. Enabling service monitoring
        3. Creating an alert rule
        4. Monitoring the service
      5. What makes a good SLA
    6. Summary
3.139.82.4