Pages

07 November 2012

Working with Apache Axis2 and SoapUI

Axis2 is easy to use and simple to develop java web services; however it requires deep undestanding to enhance java web services to support WS-* specifications with its plugin module approach. It has two kind of distributions that varies from each other with their running style:
  • WAR distribution to deploy in any servlet container
  • Standard Standalone distribution 
(Note: Source and Documentation distribution does not indicate any significant qualification to mention, here)

In order to make everything faster, I start with standalone distribution of Axis2 to test any web service with SoapUI 4.X. There is a default web service included in Axis2 that has a single method that retrieves the version information with listening both Soap 1.1 and Soap 1.2 endpoints. Start axis2 server as follows, then create a "New SoapUI Project". SoapUI will generate appropriate request skeletons to call web services on Axis2, then invoke one of them as in the screen shot below.

H:\Axis2\axis2-1.6.2\bin>axis2server.bat
Using JAVA_HOME    C:\Java\jdk1.6.0_29\jre
Using AXIS2_HOME   H:\Axis2\Download\AXIS2-~1.2
[INFO] [SimpleAxisServer] Starting
[INFO] [SimpleAxisServer] Using the Axis2 RepositoryH:\Axis2\Download\AXIS2-~1.2\repository
[SimpleAxisServer] Using the Axis2 RepositoryH:\Axis2\Download\AXIS2-~1.2\repository
[SimpleAxisServer] Using the Axis2 Configuration FileH:\Axis2\Download\AXIS2-~1.2\conf\axis2.xml
[INFO] Clustering has been disabled
[INFO] Deploying module: addressing-1.6.2 - file:/H:/Axis2/Download/AXIS2-~1.2/repository/modules/addressing-1.6.2.mar
[INFO] Deploying module: metadataExchange-1.6.2 - file:/H:/Axis2/Download/AXIS2-~1.2/repository/modules/mex-1.6.2.mar
[INFO] Deploying module: mtompolicy-1.6.2 - file:/H:/Axis2/Download/AXIS2-~1.2/repository/modules/mtompolicy-1.6.2.mar
[INFO] Deploying module: ping-1.6.2 - file:/H:/Axis2/Download/AXIS2-~1.2/repository/modules/ping-1.6.2.mar
[INFO] Deploying module: script-1.6.2 - file:/H:/Axis2/Download/AXIS2-~1.2/repository/modules/scripting-1.6.2.mar
[INFO] Deploying module: soapmonitor-1.6.2 - file:/H:/Axis2/Download/AXIS2-~1.2/repository/modules/soapmonitor-1.6.2.mar
[INFO] Deploying Web service: version.aar - file:/H:/Axis2/Download/AXIS2-~1.2/repository/services/version.aar
[INFO] Listening on port 8080
[INFO] [SimpleAxisServer] Started
[SimpleAxisServer] Started


Creating a new SoapUI Project with using WSDL on URL


Apache Axis2 Version Test with SoapUI
Thank you.