Book Image

Oracle SOA Suite 11g Developer's Cookbook

By : Antony Reynolds, Matt Wright
Book Image

Oracle SOA Suite 11g Developer's Cookbook

By: Antony Reynolds, Matt Wright

Overview of this book

<p>As part of Oracle Fusion Middleware, the components of Oracle SOA Suite enable you to build, deploy and manage Service-Oriented Architectures (SOA), and can be used as the glue to integrate your applications whilst moving your enterprise towards a service oriented future. The recipes in "Oracle SOA Suite 11g Developer's Cookbook" will provide you with a solid foundation for your SOA Suite implementation ensuring its efficiency and reliability.<br /><br />Whether you're using SOA Suite as an integration tool or as the foundation of your Service Oriented Architecture, it is important to have a reliable implementation. "Oracle SOA Suite 11g Developer's Cookbook" will ensure you have the knowledge at your disposal to achieve that, through numerous tips and tricks for extending and enhancing your applications. <br /><br />"Oracle SOA Suite 11g Developer's Cookbook" equips you with invaluable information about SOA Suite development which can usually only be gained through bitter experience. The recipes in this book distill real world experience into an easily applicable form.<br /><br />Throughout the book you'll encounter high level issues, such as building a reliable SOA Suite cluster, and detailed development problems such as avoiding errors in BPEL assignment statements. Along the way you'll also learn about configuring identity providers and managing transaction boundaries.<br /><br />The recipes in this Cookbook will prove crucial for implementing your SOA Suite solutions.</p>
Table of Contents (21 chapters)
Oracle SOA Suite 11 Developer's Cookbook
Credits
About the Authors
Contributors
About the Reviewer
www.PacktPub.com
Preface
Index

Preface

Service Oriented Architecture (SOA) provides the architectural framework needed to integrate diverse systems together and create new composite applications. Oracle SOA Suite 11gR1 provides the tools needed to turn an SOA architecture into a working solution. SOA Suite provides the developer with several high level components such as:

  • Oracle Service Bus (OSB), an enterprise strength service bus for full support of service bus patterns including validation, enrichment, transformation, and routing (the VETRO pattern)

  • Service Component Architecture (SCA) that hosts a number of components

  • Business Activity Monitoring (BAM) that provides real-time reporting on SOA Suite activities

SCA components include:

  • Mediator for light weight transformation and routing

  • Rules for abstraction of business rules

  • BPEL for orchestrating long running or complex integrations

  • Human workflow (HWF) for allowing human interaction with long running processes

  • Spring for integrating Java Spring components

This book looks at many common problems that are encountered when integrating systems and provides solutions to them in the form of more than 67 cookbook recipes. The solutions explain the problem to be solved alongside clear step by step instructions to implement a solution using SOA Suite components. Each recipe also includes a discussion of how it works and what additional problems may be tackled by the solution presented.

What this book covers

Chapter 1, Building an SOA Suite Cluster, explains how to prepare the environment to follow Oracle's Enterprise Deployment Guide. The Enterprise Deployment Guide is Oracle's blueprint for building a highly available SOA Suite cluster. The chapter includes key questions to ask the network storage team, the networking team, and the Database Administrators before the actual SOA Suite installation and deployment begins.

Chapter 2, Using the Metadata Service to Share XML Artifacts, explains how we can use MDS to share XML artifacts, such as XML schemas, WSDL's fault policies, XSLT Transformations, EDLs for event EDN event definitions and Schematrons between multiple composites.

Chapter 3, Working with Transactions, looks at the different ways to use transactions within SOA Suite. This includes enrolling a BPEL process in an existing transaction, forcibly committing or aborting a transaction within BPEL and catching faults that have caused the transaction to be rolled back. It also covers how to apply reversing transactions when a system does not support transaction functionality in its public interface.

Chapter 4, Mapping Data, covers how to copy and transform data using the SCA container. It includes how to deal with missing XML elements and how to control the mapping of Java objects to XML including dealing with abstract Java classes. It also covers how to process arrays of data in both BPEL and XML stylesheet transforms (XSLT).

Chapter 5, Composite Messaging Patterns, explores some of the more complex but relatively common message interaction patterns used in a typical SOA deployment. It includes recipes for implementing patterns around message aggregation, singletons, and the dynamic scheduling of BPEL processes and services.

Chapter 6, OSB Messaging Patterns, explores some common message processing design patterns for delegation of execution to downstream services and provides recipes for implementing them using Oracle Service Bus. It includes recipes for dynamic binding to services, splitting out messages, as well as dynamic Split-Joins.

Chapter 7, Integrating OSB with JSON, covers how we can use the Service Bus to integrate with RESTful web services that exchange data using JavaScript Object Notation (JSON) instead of XML. It also looks at how to expose OSB Services as RESTful JSON web services.

Chapter 8, Compressed File Adapter Patterns, explains how to use the file/FTP adapter to compress/uncompress the contents of exchanged files. This is particularly common in Business-to-Business scenarios, where network bandwidth is more of a constraint.

Chapter 9, Integrating Java with SOA Suite, explains different ways to integrate Java code into SOA Suite. This is demonstrated through creating a custom XPath function for use in SCA and OSB, as well as re-using EJBs and Spring Beans in SOA Suite. It also shows how to access the SOA runtime environment from within a BPEL process.

Chapter 10, Securing Composites and Calling Secure Web Services, shows the developer how to restrict access to a composite by applying a security policy, as well as showing how to create a new security policy. It also explains how to make a call to a security protected service and how to manage security stores.

Chapter 11, Configuring the Identity Service, details how to configure the Oracle Platform Security Services (OPSS) to use various LDAP providers for authentication and authorization within the Oracle SOA Suite. It covers configuration for Active Directory, Oracle Internet Directory, Sun iPlanet, and Oracle Virtual Directory.

Chapter 12, Configuring OSB to use Foreign JMS Queues, covers how to configure the Service Bus to read/write messages from various JMS providers, including OC4J, JBoss, and across WebLogic domains.

Chapter 13, Monitoring and Management, includes recipes to monitor the completion status of SOA composites through the EM dashboard, measuring their message throughput in real time. It also covers setting up the SOA environment to use the SOA Suite provided Monitor Express reports to take advantage of pre-built BAM dashboards.

What you need for this book

This book was written using Oracle SOA Suite 11.1.1.6 and Oracle JDeveloper 11.1.1.6 with the SOA Suite design extensions. The contents are relevant for all SOA Suite 11gR1 releases, although some features may not be available in revisions before 11.1.1.6 and some screenshots may vary between revisions.

Who this book is for

This book will benefit SOA Suite developers, designers, and architects who want to get the most value out of their SOA Suite investments.

Conventions

In this book, you will find a number of styles of text that distinguish between different kinds of information. Here are some examples of these styles, and an explanation of their meaning.

Code words in text are shown as follows: "Run the leasing.ddl script as the leasing user."

A block of code is set as follows:

Operation getTotalPrice( book_list ):
  totalPrice := 0
  for each order in book_list
  loop
    total_price := total_price + 
      Book.priceCheck(order.isbn ) * order.qty
  end loop
  return total_price

When we wish to draw your attention to a particular part of a code block, the relevant lines or items are set in bold:

Operation getTotalPrice( book_list ):
  totalPrice := 0
  for each order in book_list
  loop
    total_price := total_price +
      Book.priceCheck(order.isbn ) * order.qty
  end loop
  return total_price

New terms and important words are shown in bold. Words that you see on the screen, in menus or dialog boxes for example, appear in the text like this: "Open your proxy service and select the Message Flow tab."

Note

Warnings or important notes appear in a box like this.

Tip

Tips and tricks appear like this.

Reader feedback

Feedback from our readers is always welcome. Let us know what you think about this book—what you liked or may have disliked. Reader feedback is important for us to develop titles that you really get the most out of.

To send us general feedback, simply send an e-mail to , and mention the book title via the subject of your message.

If there is a topic that you have expertise in and you are interested in either writing or contributing to a book, see our author guide on www.packtpub.com/authors.

Customer support

Now that you are the proud owner of a Packt book, we have a number of things to help you to get the most from your purchase.

Downloading the example code

You can download the example code files for all Packt books you have purchased from your account at http://www.PacktPub.com. If you purchased this book elsewhere, you can visit http://www.PacktPub.com/support and register to have the files e-mailed directly to you.

Errata

Although we have taken every care to ensure the accuracy of our content, mistakes do happen. If you find a mistake in one of our books—maybe a mistake in the text or the code—we would be grateful if you would report this to us. By doing so, you can save other readers from frustration and help us improve subsequent versions of this book. If you find any errata, please report them by visiting http://www.packtpub.com/support, selecting your book, clicking on the errata submission form link, and entering the details of your errata. Once your errata are verified, your submission will be accepted and the errata will be uploaded on our website, or added to any list of existing errata, under the Errata section of that title. Any existing errata can be viewed by selecting your title from http://www.packtpub.com/support.

Piracy

Piracy of copyright material on the Internet is an ongoing problem across all media. At Packt, we take the protection of our copyright and licenses very seriously. If you come across any illegal copies of our works, in any form, on the Internet, please provide us with the location address or website name immediately so that we can pursue a remedy.

Please contact us at with a link to the suspected pirated material.

We appreciate your help in protecting our authors, and our ability to bring you valuable content.

Questions

You can contact us at if you are having a problem with any aspect of the book, and we will do our best to address it.