tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Travis Beech <travis.be...@gmail.com>
Subject RE: multiple URI
Date Wed, 20 Jan 2010 07:48:59 GMT
Modify your servlet mapping in your web.xml so that you have more than one
mapping to that servlet.

Take the following xml snippet as an example, each of the three servlet
mappings will map to a single servlet. This would allow someone to use three
different URL's to access the same servlet.

<servlet>
  <servlet-name>RequestFactory</servlet-name>
  <servlet-class>com.foo.web.servlet.RequestFactory</servlet-class>
</servlet>
<servlet-mapping>
  <servlet-name>RequestFactory</servlet-name>
  <url-pattern>/RequestFactory</url-pattern>
</servlet-mapping>
<servlet-mapping>
  <servlet-name>RequestFactory</servlet-name>
  <url-pattern>/Request</url-pattern>
</servlet-mapping>
<servlet-mapping>
  <servlet-name>RequestFactory</servlet-name>
  <url-pattern>/SomeOtherUrl </url-pattern>
</servlet-mapping>

-----Original Message-----
From: Vadym Chepkov [mailto:chepkov@yahoo.com] 
Sent: Tuesday, January 19, 2010 12:17 PM
To: users@tomcat.apache.org
Subject: multiple URI

Greetings,

I want a servlet to serve two different urls: http://server/A and
http://server/B, but I don't want to install this servlet as a ROOT servlet.
Is this possible in tomcat 6?

Thank you.
Sincerely yours,
  Vadym Chepkov

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@tomcat.apache.org
For additional commands, e-mail: users-help@tomcat.apache.org


Mime
View raw message