Tomcat Connectors

Tomcat Connectors

A Tomcat connector is a component that listens for connections and allows them to be serviced by Tomcat.

Configuration is inside the file conf/server.xml. A typical development setup for Tomcat might have a connector to service HTTP requests on port 80, and another HTTPS connector for port 443.

One other connector I've used is AJP, which is used by Apache to talk to Tomcat.

To restrict the network interface the connector is listening on, specify the address attribute. In the following example it will only listen on the local loopback interface. Depending on your environment, this could provide additional security.

<Connector port="8012" address="" enableLookups="false" protocol="AJP/1.3" />

Published: Saturday, 23 October 2010