tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Egor Samarkhanov <>
Subject Single virtual tomcat application which serves multiple contexts
Date Fri, 20 Jan 2012 15:56:43 GMT
Hello !

I have multiple clients:
  client 1 - 40 users
  client 2 - 50 users
  client 3 - 60 users

And I have a web application that is supposed to serve the clients.
The application is deployed into Tomcat. Each client has it's own database.

What I want to implement is the single web application instance which
servers all  the clients. The client (and the database to connect to)
is identified by the context path from the URL.

I.e. I imply the following scenario:

1. Some user requestes the
2. Tomcat invokes a single instance of my application (no matter
   which  context is requested)
3. My application processes the rest of the request thinking that it's
   deployed to /client1 context path, i.e. all redirect or relative URLs
   should be resolved against

When the client 2 requests the, I want my
application (the same instance) now process it just like if it was
deployed to /client2 context path.

Is this possible in Tomcat?

thanks in advance

Best regards,
Egor Samarkhanov (
Actimind, Inc.

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message