Friday, November 16, 2012

Creating an opentravel SOAP client and server for testing using soapui

If you are creating a web services client or server in the Travel Industry, you are probably using the opentravel messaging schema.

Sometimes the most difficult part of your project is creating a test client or server to verify your application code.

soapui is a great open source utility for easily creating manual and automated SOAP test suites.

I'm going to show you how to quickly set up a SOAP test client and a SOAP test server for an opentravel message pair using soapui.

The first thing you will need is a WSDL file. Luckily the ota-tools project has many open source resources for opentravel users, including a soapui project with sample WSDL file that we can use as a template.

You can download this WSDL file from the ota-tools source repository at:

This WSDL is currently configured for the 2012A version of the Ping message pair. If you would like to use a different message pair, just change the import statements to point to your root schema.

For example, if I want to test the cancellation message pair, I would change:

<xsd:import namespace=""
  schemaLocation="" />
<xsd:import namespace=""
  schemaLocation="" />

<xsd:import namespace=""
  schemaLocation="" />
<xsd:import namespace=""
  schemaLocation="" />

Then change the message root elements to match the root elements of the schema that you are testing. In this example, I would change:

<wsdl:message name="Request">
<wsdl:part element="ota:OTA_PingRQ" name="payload">
<wsdl:message name="Response">
<wsdl:part element="ota:OTA_PingRS" name="payload">

<wsdl:message name="Request">
<wsdl:part element="ota:OTA_CancelRQ" name="payload">
<wsdl:message name="Response">
<wsdl:part element="ota:OTA_CancelRS" name="payload">

Now you are ready to create a test client and server in soapui.

From the soapui main menu, select, File -> New soapui Project

In the dialog box, click the browse button and open the wsdl file that you just edited:

Give your project and name and click 'OK'

Generate a default service

and give it a name:

Now you are ready to start your mock service. Click on the green 'Go' button in the upper left. Now your service is running and you can call it from soapui or the opentravel client that you are developing.

Now let's test our service. Open the sample request and,

press the green 'Go' button in the upper left. You should have a response message on your screen.
 VoilĂ !

Now you are ready to add some logic to your soapui test server and create a soapui client test suite. You will find a nice project with examples in the ota-tools soapui project.

This sample project is located in our source repository at:

Just download the opentravel-soapui-project.xml file and import it into soapui.

Now you're ready to test your opentravel client or server code!


iphone developers said...

thanks for sharing the post

Aadam Gibson said...

Great stuff. Thanks to post this kind of knowledgeable blog.

Innovapath said...

Excellent Post. Also visit

Verna J. Lacombe said...

This is a fantastic publish regarding android operating system development! Those who want to understand such will absolutely find these training useful and beneficial.Ecommerce Web Design

Anandmahalakshmi said...

great article. I would like to get support for PHP Integration as well. Can you give idea about it?

Steve Smith said...

Great and Useful Article.

Java Web Services Training

Java Web Services Training

Whizdom Trainings said...

hi,we provide online training & video tutorial for soapui
for free videos refer

John Alert said...

Java Web Services Training in Chennai Java Web Services Training in Chennai Java Web Services Online Training Java Web Services Training in Chennai

John Alert said...

Java Training Institutes Java Training Institutes Core Java Training Institutes in Chennai
Java Spring Hibernate Training Institutes in Chennai Java Spring Hibernate Training Institutes in Chennai | Hibernate Training Institutes in Chennai J2EE Training Institutes in Chennai J2EE Training Institutes in Chennai

Divya madhuri said...

I have read your article its very nice attractive and impressive. I like it your article.Let me share useful information for CCNA jobs in Hyderabad

Abhishek Bhardwaj said...

Nice Post . Thank you for this beautiful content, Keep it up. Techavera is the best Institute in Noida for all these main Courses below:-

MCITP training in Noida
MS sql server Training in Noida
Cloud Computing Training Institute in Noida
CCNP Training Institute in Noida
Manual Testing Training Institute in Noida
ANSYS training course in noida

Visit us For Quality Learning.Thank you

selir selir said...

just information we only provide information for those who need it cara menggugurkan hamil
A. cara agar cepat hamil setelah selesai haid
B. cara agar cepat hamil
C. cara alami untuk segera mendapat kehamilan
D. makanan dan minuman agar cepat hamil
E. masa subur biar cepat hamil
F. panduan agar cepat hamil

Devi.Angularjs said...

Great Article. Thank you for sharing! Really an awesome post for every one.

IEEE Final Year projects Project Centers in Chennai are consistently sought after. Final Year Students Projects take a shot at them to improve their aptitudes, while specialists like the enjoyment in interfering with innovation. For experts, it's an alternate ball game through and through. Smaller than expected IEEE Final Year project centers ground for all fragments of CSE & IT engineers hoping to assemble. Final Year Project Domains for IT It gives you tips and rules that is progressively critical to consider while choosing any final year project point.

JavaScript Training in Chennai

JavaScript Training in Chennai