After deploying the Apache Axis2 engine in a runtime environment for IBM WebSphere Application Server, the Apache Axis2 servlet is not accessible. Apache Axis2 applications do not run in a runtime environment for WebSphere Application Server.
Prior to Version 1.4.1 of the Apache Axis2 engine, the Web application was packaged with libraries that attempt to override the standard servlet classes in the runtime environment for WebSphere Application Server. This process does not comply with the constraints of the Java™ Servlet Specification, Version 2.5, section SRV.9.7.2.
Resolving The Problem
Complete one of the following steps if you attempt to deploy the Apache Axis2 engine onto WebSphere Application Server V7.0 and you encounter errors:
- If you can upgrade to Apache Axis2 V1.4.1 engine, you must perform the following steps. These steps change the structure of the Apache Axis2 Web application so that it is recognized by WebSphere Application Server:
- Locate the WEB-INF/modules directory within the Apache Axis2 Web application. The WEB-INF/modules directory contains the archive files, which are required by the Apache Axis2 run time.
Note: These files do not have a .jar extension and the files do not exist in the WEB-INF/lib directory.
According to section SRV.9.5 in version 2.5 of the Java Servlet specification, the default class path of a Web application includes the classes in the WEB-INF/classes directory and any files that end with a .jar extension in the WEB-INF/lib directory.
- Copy any files that end with a .mar extension in the WEB-INF/modules directory of the Axis2 Web application to the WEB-INF/lib directory. Rename these files with a .jar extension.
Important: Do not use the move function, but copy the files from the WEB-INF/modules directory to the WEB-INF/lib directory. The Apache Axis2 engine looks for the files in the WEB-INF/modules directory. However, the files must reside in the WEB-INF/lib directory with the .jar extension so that the files are visible to the class loaders for WebSphere Application Server.
- Deploy the Apache Axis2 V1.4.1 engine on WebSphere Application Server.
- Change the class loading policy of the Apache Axis2 V1.4.1 Web application to ensure that the parent class loader of the application is used last when the class loader searches for classes. Make sure that you change the class loading policy for the Web application archives (WAR) module containing Axis2. Do not change the class loading policy for the application enterprise archive (EAR) file.
For more information on the configuring application class loaders, see the Configuring application class loaders topic in the Information Center for WebSphere Application Server Version 7.0.
Note: WebSphere Application Server provides a JAX-WS engine. When you deploy the Apache Axis2 engine with the IBM provided engine, the engine is treated as a third-party JAX-WS engine. To avoid possible conflicts, disable the IBM provided engine. See this link:
http://www-01.ibm.com/support/docview.wss?uid=swg1PK93756 for more information.
Was this topic helpful?
15 June 2018