Search icon CANCEL
Subscription
0
Cart icon
Your Cart (0 item)
Close icon
You have no products in your basket yet
Save more on your purchases now! discount-offer-chevron-icon
Savings automatically calculated. No voucher code required.
Arrow left icon
Explore Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Conferences
Free Learning
Arrow right icon
Arrow up icon
GO TO TOP
Oracle Service Bus 11g Development Cookbook

You're reading from   Oracle Service Bus 11g Development Cookbook

Arrow left icon
Product type Paperback
Published in Jan 2012
Publisher Packt
ISBN-13 9781849684446
Length 522 pages
Edition 1st Edition
Languages
Arrow right icon
Toc

Table of Contents (19) Chapters Close

Oracle Service Bus 11g Development Cookbook
Credits
About the Authors
About the Reviewers
www.PacktPub.com
Preface
1. Creating a basic OSB service 2. Working Efficiently with OSB Artifacts in Eclipse OEPE FREE CHAPTER 3. Messaging with JMS Transport 4. Using EJB and JEJB transport 5. Using HTTP Transport 6. Using File and Email Transports 7. Communicating with the Database 8. Communicating with SOA Suite 9. Communication, Flow Control, and Message Processing 10. Reliable Communication with the OSB 11. Handling Message-level Security Requirements 12. Handling Transport-level Security Requirements Index

Testing the proxy service through the OSB console


With the OSB configuration deployed successfully to our OSB server, it's time to test it. This recipe will show the most basic way to test, using the OSB console. This is good enough for some initial test but in the long term something more repeatable is necessary. One alternative option is using soapUI, which will be covered in the next recipe.

Getting ready

Navigate to the OSB console and login as the Administrator (that is, weblogic).

How to do it...

In the OSB console, perform the following steps:

  1. Click on the menu item Project Explorer on the left-hand side of the OSB console.

  2. In the project tree, click on basic-osb-service and in the details section on the right, the project folder tree will be shown.

  3. Click on the proxy link.

  4. The proxy service Customer Service should be displayed in the details section (might have to scroll down to see it):

  5. Click on the bug symbol in the Actions section (highlighted in red in the preceding screenshot) to open the test window for the Customer Service proxy service.

  6. In the Proxy Service Testing window, make sure you select the right operation in the Available Operations drop-down list. We want to test the RetrieveCustomerByCriteria operation.

  7. Change the Payload field as shown in the following screenshot:

  8. Click on the Execute button to run the test. The test results are returned after a while in the same window:

  9. Check that the right customer (with ID = 1) information is being returned by the OSB service.

  10. Scroll down in the window to see the Invocation Trace section. This will show steps that the OSB proxy service has executed and values of the variables during execution:

How it works...

Due to the fact that the interface of the proxy service is clearly defined through the WSDL, the OSB console is capable of showing us a sample test message in the Payload field. If we have a proxy service without a WSDL, then testing that service will still be possible through that window, but there will no longer be a sample message shown, as the OSB console does not know about the structure.

The testing capabilities offered by the OSB console are good for some initial tests or if the execution trace is of value, possibly for debugging if using the graphical debugger is not an option. The limitation of the OSB console for testing is clearly that there is no way to persist a test case to be able to run it again later. By that it's also not possible to automate and repeat testing, for example, to start tests inside a nightly build. For that, soapUI, which will be shown in the next recipe, is much better suited.

See also

An alternative way for testing proxy services can be found in the next recipe Testing the proxy service through soapUI.

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $19.99/month. Cancel anytime