How to connect Apache Tomcat to IIS using AJP13 connector

If you are here, you are curious and have a need to connect JVM servlet driven infrastructure components running on Windows Operating System to IIS. Your servlet container could be anything like Tomcat, JBoss, Jira, etc., but for the remainder of this post we will assume the use of Apache Tomcat.

We will also assume you don’t want to get a new degree in computer science, changing configuration files, mucking with virtual directories and different bit versions of distribution files.

IIS and Tomcat don’t talk, meaning these technologies don’t normally talk to each other in-process via native calls. They are separate processes operating independently.

Tomcat is not connected to IIS

Thus, we will have to use an out-of-process connection between these two technologies in form of a protocol. We will use AJP version 1.3. There are a other protocols and ways to connect them, however, for our purposes we will focus on this:

Tomcat connected via BonCode AJP 13 to IISWe will use the BonCode connector. Please download it from the main connector page. The BonCode connector works in-process with IIS and adds AJP 1.3 protocol support to IIS so that we can pass web request with high fidelity to Tomcat for processing and return responses correctly to callers.

The installation of this connector is by far the simplest methodology currently available.

After you have installed Tomcat and IIS. It boils down to three steps:

a) Download distribution package

Please go to link above and click on the current downloadable version.

b) unblock distribution package and unzip

After you have downloaded the installation package you will need to make sure that you can execute the installation correctly.

To avoid multiple issues with using the zip file content I would recommend that you unblock the zip package before unzipping. This avoids security issues with Windows Vista and later operating systems as well as Windows 2008 and later server operating systems. Simply right click on the zip file and click “Unblock” on the “General” tab.

Unblock Download Package

 

c) run installer and answer questions

Double click on the Connector_Setup.exe to start the installer. Accepting the installer defaults should get your system up and running. This will assume that all your IIS sites are connected to Tomcat. If not, change the answers where appropriate and select the sites to be connected.

image002

 

More background information is available. There are more options and elements that you can choose from, but this is all you need to get going. To learn more visit the online manual.

 

Youtube Videos

For those who rather watch the whole process here are some videos that walk through a few scenarios