• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Paul Clapham
  • Jeanne Boyarsky
  • Liutauras Vilda
Sheriffs:
  • Rob Spoor
  • Bear Bibeault
  • Tim Cooke
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Piet Souris
Bartenders:
  • Frits Walraven
  • Himai Minh

Apache web server tomcat : Connector protocol conflict

 
Ranch Hand
Posts: 53
Android C++ Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
There's something i dont quite understand as shown below:

a. Apache web server httpd.conf

ProxyPass /cgi-qa-axis-rt/ ajp://localhost:8988/cgi-qa-axis-rt/
ProxyPassReverse /cgi-qa-axis-rt/ ajp://localhost:8988/cgi-qa-axis-rt/

b. On the cgi-qa-axis-rt context, the server.xml is as follows:

<!-- -->
<Connector executor="tomcatThreadPool"
port="8988" protocol="HTTP/1.1"
connectionTimeout="20000"
redirectPort="8443" />

<!-- Define a SSL HTTP/1.1 Connector on port 8443
This connector uses the JSSE configuration, when using APR, the
connector should be using the OpenSSL style configuration
described in the APR documentation -->
<!--
<Connector port="8443" protocol="HTTP/1.1" SSLEnabled="true"
maxThreads="150" scheme="https" secure="true"
clientAuth="false" sslProtocol="TLS" />
-->

<!-- Define an AJP 1.3 Connector on port 8009 -->
<!--Connector port="8888" protocol="AJP/1.3" redirectPort="8443" connectionTimeout="3000000" keepAliveTimeout="3000000" /-->


Question:
Apache web server will transfer the request to cgi-qa-axis-rt using ajp protocol. In cgi-qa-axis-rt server.xml, this ajp connector port is commented out. In cgi-qa-axis-rt server.xml, port 8988 is using HTTP protocol.
Why does it work?
Apache managed to transfer request to cgi-qa-axis-rt.
Strange
 
Sheriff
Posts: 22213
117
Eclipse IDE Spring VI Editor Chrome Java Windows
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
As far as I can tell, ProxyPass forwards the request to port 8988 - the HTTP connector, not the AJP connector. So it doesn't look so strange to me.
 
Kim Ming Yap
Ranch Hand
Posts: 53
Android C++ Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The proxypass statements, if you read carefully:

ProxyPass /cgi-qa-axis-rt/ ajp://localhost:8988/cgi-qa-axis-rt/

it is mapping /cgi-qa-axis-rt/ to localhost:8988/cgi-qa-axis-rt/ using ajp protocol. So it is not using HTTP in this statements. This statement is in apache web server httpd.conf.

However the tomcat server.xml for cgi-qa-axis-rt context in localhost is defined with HTTP connector for port 8988. The AJP connector has been commented out.

It still works. That's what puzzles me.
 
Saloon Keeper
Posts: 23774
161
Android Eclipse IDE Tomcat Server Redhat Java Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I would check to see if you have 2 copies of Tomcat running, then. Because either your proxy definition isn't the one being used, or something is out there listening and responding on port 8988. Unless an application opens a port, attempts to communicate with that port will bounce.
reply
    Bookmark Topic Watch Topic
  • New Topic