Load and install the HTTP proxy servlet file on Apache Tomcat.
Before you begin
Before you deploy the HTTP proxy servlet, you must complete the following tasks:
About this task
Install and customize Apache Tomcat, and then deploy the HTTP proxy servlet by completing the
following steps. The instructions assume that IBM App Connect Enterprise is installed
and running on the same machine as Apache Tomcat.
Procedure
- Download Apache Tomcat from the Apache
Tomcat 9 download page.
- Run the Apache Tomcat installer and follow the instructions to complete the
installation.
Note: When prompted for the path to a Java™ virtual machine
(JVM) you can use the JVM that is deployed with IBM App Connect Enterprise, for example
C:\Program Files\IBM\ACE\13.0.n.0\common\jdk\jre.
- Find the file catalina.properties.
This can be found at the following location:
Tomcat_installation_path/conf/catalina.properties
where Tomcat_installation_path is the name of your Apache Tomcat installation
directory.
- Edit catalina.properties and locate the following line:
- Edit the line so that it includes the following text:
shared.loader=${catalina.home}/shared/lib,${catalina.home}/shared/lib/*.jar
- Create the directory
Tomcat_installation_path/shared/lib.
- Copy the following IBM MQ JAR files from
WebSphere_MQ_installation_path\Java\lib to
Tomcat_installation_path\shared\lib:
- com.ibm.mq.commonservices.jar
- com.ibm.mq.headers.jar
- com.ibm.mq.jar
- com.ibm.mq.jmqi.jar
- com.ibm.mq.pcf.jar
- connector.jar
The HTTP proxy servlet uses
IBM MQ to communicate with
IBM App Connect Enterprise.
- Start the Apache Tomcat Windows service.
- Open a web browser and enter the web address
http://localhost:port where port is the
HTTP port number you specified in the Apache Tomcat installation.
The default value for
the port is 8080.
The Apache Tomcat home page is displayed.
- Click Tomcat Manager and enter the admin user ID and
password.
- Scroll down to the section WAR file to deploy and click
Browse.
- Navigate to the HTTP proxy servlet file that you exported from IBM App Connect Enterprise.
For example,
myproxyservlet.war.
Note: By default in Apache Tomcat, the context root that is used by the HTTP proxy servlet is the
same as the
.war file name. You can rename the
.war file
before you deploy the HTTP proxy servlet in order to assign a different context root to the HTTP
proxy servlet. For information about the context root, see
Importance of the context root when you configure the HTTP proxy servlet. If you want
the HTTP proxy servlet to use an empty context root (
/
), then you must rename the
.war file to
ROOT.war and uninstall the current default
web application (the Tomcat Welcome page).
- Click Deploy.
- To test if the HTTP proxy servlet is active, enter the following URL in a web
browser:
http://host_name:port/context_root
where:
- host_name
- Specifies the host name of your Apache Tomcat server.
- port
- Specifies the port number of your Apache Tomcat server.
- context_root
- Specifies the context root that you assigned to the HTTP proxy servlet.
For example: http://localhost:8080/.
If the HTTP proxy servlet can reach the
integration node, you should
get an
HTTP Status 404
response with the following error
message:
URI / does not map to any message flow in integration node integration_node
where
integration_node is the name of your integration node.
Results
The proxy servlet is deployed on your Apache Tomcat server.
What to do next
The HTTP proxy servlet is now ready to be tested with an integration node
that receives HTTP (not HTTPS) requests and passes them to a message flow. For information about how
to complete this task, see Testing the HTTP proxy servlet.