Access the servlets directly via port 80

What if I like to access the servlets directly via port 80 instead of using :portnumber on my URL?

You can do a trick, Edit apache virtual host entry and add the JkMount directive.
For example: I wanted to access a servlet which was under seed directory of my document root. I was able to access the servlet at http://domainname.com:8080/seed/servlet/<ServletNAME>
All I wanted to do is to simplify the above URL to look like :

http://domainname.com/seed/servlet/<ServletNAME>

This is not possible as appBase and DocBase are set to my domains Document root.
Hence I had make use of JkMount directive in VirtulHost entry as follows to change the appBase for the servler URI as follows :
<IfModule mod_jk.c>
JkMount /*.do ajp13
JkMount /*.jsp ajp13
JkMount /seed/servlet/* ajp13
JkMount /seed/servlets/* ajp13
JkMount /manager/* ajp13
</IfModule>
Now my URL works as needed.

Both comments and pings are currently closed.

Comments are closed.

Powered by WordPress | iFreeCellPhones.com has the Best Cell Phone Deals. | Thanks to PalmPreBlog.com, Find Best CD Rates and Fat burning furnace
snowflake snowflake snowflake snowflake snowflake snowflake snowflake snowflake snowflake snowflake snowflake snowflake snowflake snowflake snowflake snowflake snowflake snowflake snowflake snowflake

Search engine optimization by SEO Design Solutions