Allow Apache to Serve Static Content
Hi all, I have Apache integrated with Tomcat using mod_jk2 and all is working well with the exception of performance. I would like to direct Apache to serve the static content components of my Java application. How is this done? I presume there must be some type of httpd.conf setting to do this? David A. Morrow Technical Systems Lead Autodata Solutions Company [EMAIL PROTECTED] http://www.autodata.net Tel: (519) 951-6079 Fax: (519) 451-6615 Poor planning on your part does not necessarily constitute an emergency on my part. This message has originated from Autodata Solutions. The attached material is the Confidential and Proprietary Information of Autodata Solutions. This email and any files transmitted with it are confidential and intended solely for the use of the individual or entity to whom they are addressed. If you have received this email in error please delete this message and notify the Autodata system administrator at [EMAIL PROTECTED] mailto:[EMAIL PROTECTED]
Re: Allow Apache to Serve Static Content
Point the DocumentRoot directory to your webapps directory. Then, in your jk mapping, map only *.jsp and *.servlet to Tomcat. ## WEBSITE ## VirtualHost * ServerAdmin [EMAIL PROTECTED] DocumentRoot /code/www/webapps/website/ROOT ServerName www.website.com CustomLog |/code/utils/cronolog/cronolog /logs/apache/website_access_log_%Y_%m_%d.txt combined ErrorLog |/code/utils/cronolog/cronolog /logs/apache/website_error_log_%Y_%m_%d.txt JkMount /*.jsp tomcat JkMount /*.do tomcat /VirtualHost Charlie Dave Morrow said the following on 2/15/2005 3:25 PM: Hi all, I have Apache integrated with Tomcat using mod_jk2 and all is working well with the exception of performance. I would like to direct Apache to serve the static content components of my Java application. How is this done? I presume there must be some type of httpd.conf setting to do this? David A. Morrow Technical Systems Lead Autodata Solutions Company [EMAIL PROTECTED] http://www.autodata.net Tel: (519) 951-6079 Fax: (519) 451-6615 Poor planning on your part does not necessarily constitute an emergency on my part. This message has originated from Autodata Solutions. The attached material is the Confidential and Proprietary Information of Autodata Solutions. This email and any files transmitted with it are confidential and intended solely for the use of the individual or entity to whom they are addressed. If you have received this email in error please delete this message and notify the Autodata system administrator at [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Allow Apache to Serve Static Content
rather than setup tomcat + jk2 + apache, I would recommend setting up a dedicated image server. If you look at the static file benchmark results I posted recently, tomcat is actually faster for 1k files and equal to apache for larger than 1k files. http://cvs.apache.org/~woolfel/tc_results.html I hope that helps peter On Tue, 15 Feb 2005 15:25:28 -0500, Dave Morrow [EMAIL PROTECTED] wrote: Hi all, I have Apache integrated with Tomcat using mod_jk2 and all is working well with the exception of performance. I would like to direct Apache to serve the static content components of my Java application. How is this done? I presume there must be some type of httpd.conf setting to do this? David A. Morrow Technical Systems Lead Autodata Solutions Company [EMAIL PROTECTED] http://www.autodata.net Tel: (519) 951-6079 Fax: (519) 451-6615 Poor planning on your part does not necessarily constitute an emergency on my part. This message has originated from Autodata Solutions. The attached material is the Confidential and Proprietary Information of Autodata Solutions. This email and any files transmitted with it are confidential and intended solely for the use of the individual or entity to whom they are addressed. If you have received this email in error please delete this message and notify the Autodata system administrator at [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
Re: Allow Apache to Serve Static Content
This assumes of course that you are running Apache and Tomcat on the same server. The concept is pretty much the same though. You set the DocumentRoot to where your static files reside on Apache and map your JSPs and servlets to your JK worker that redirects the request to your Tomcat instance. On Tue, 15 Feb 2005 15:48:18 -0500, Charles N. Harvey III [EMAIL PROTECTED] wrote: Point the DocumentRoot directory to your webapps directory. Then, in your jk mapping, map only *.jsp and *.servlet to Tomcat. ## WEBSITE ## VirtualHost * ServerAdmin [EMAIL PROTECTED] DocumentRoot /code/www/webapps/website/ROOT ServerName www.website.com CustomLog |/code/utils/cronolog/cronolog /logs/apache/website_access_log_%Y_%m_%d.txt combined ErrorLog |/code/utils/cronolog/cronolog /logs/apache/website_error_log_%Y_%m_%d.txt JkMount /*.jsp tomcat JkMount /*.do tomcat /VirtualHost Charlie Dave Morrow said the following on 2/15/2005 3:25 PM: Hi all, I have Apache integrated with Tomcat using mod_jk2 and all is working well with the exception of performance. I would like to direct Apache to serve the static content components of my Java application. How is this done? I presume there must be some type of httpd.conf setting to do this? David A. Morrow Technical Systems Lead Autodata Solutions Company [EMAIL PROTECTED] http://www.autodata.net Tel: (519) 951-6079 Fax: (519) 451-6615 Poor planning on your part does not necessarily constitute an emergency on my part. This message has originated from Autodata Solutions. The attached material is the Confidential and Proprietary Information of Autodata Solutions. This email and any files transmitted with it are confidential and intended solely for the use of the individual or entity to whom they are addressed. If you have received this email in error please delete this message and notify the Autodata system administrator at [EMAIL PROTECTED] mailto:[EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] - To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]