But Apache2.2 web server can't pass "http://localhost/jws/Calculator.jsp" for processing to the Tomcat 6 server on my local test machine.
My httpd.conf file has the following lines:
This is what the hosting service has to say about mount directives:
Under the shared Apache/Tomcat implementation as we have here (per Apache’s specifications and industry-standard for a shared platform), all requests go through Apache first, and as such, specific mount directives have to be defined in Apache to pass the JSP/Servlet/Mapping from Apache to Tomcat (otherwise Apache will assume it should try processing the request). By default, the directives we pass are:
We pass the three standard mount directives:
How do I configure the my local Apache/Tomcat system to behave more like the hosting service?
(I struggled for far to long with this, I'm not an expert with Apache/Tomcat configuration and may be looking at the wrong things)
Study the way the applications that Tomcat comes with are configured.
You got me thinking what was really happening at the hosting service implementation. The clue was that the WEB-INF directory appears inside my "httpdocs" directory. They do not allow users to upload war files for a reason:
Support Center » Knowledgebase » Tomcat (JSPs/Servlets) » Are .war files supported on your servers?
Solution In our shared Apache/Tomcat implementation, .war files are not supported (noted on our main website). You must unarchive your .war into your httpdocs directory. The container-standard /WEB-INF directory structure is preprovided.
My "jws" directory along with all the web files are loaded into the httpdocs directory.
On my localhost, I made junctions back into my WebContent development directories.
First, I shutdown the Apache and Tomcat service. Then renamed the Tomcat directories "webapp/ROOT" to "webapp/ROOT.bu' and "webapp/servlet" to "webapp/servlet.bu" to get them out of the way.
These are the commands I used to establish links back to my WebContent development directory:
Then I copy the files from the renamed servlet.bu into D:\home\jsemler.net\WebContent and restart the Apache and Tomcat installation.
Not an elegant solution but it works. I would also lose my Tomcat Manager Web page and the ability to use war files (because I took over "ROOT"). I only possess rudimentary knowledge of how to configure Apache/Tomcat/Windows 7 system so my chances are low in finding a better solution without investing a lot of time.
You showed up just in time for the waffles! And this tiny ad:
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop