• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Dynamically Configure Tomcat

 
Ranch Hand
Posts: 282
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Is there a mechanism to dynamically configuring Tomcat? Specifically, I am interested in being able to dynamically change the subdomains and servlet mappings Tomcat would respond to. I've been looking thru the Tomcat API and, while it appears this might to be possible, I have been unable to find any real code examples. If it is possible, can someone point me to some code examples or at least in the right direction?
 
Author and all-around good cowpoke
Posts: 13078
6
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Using the Management app you can undeploy an application, change the web.xml (with a text editor or whatever), and redeploy it to use the new values.

Bill
 
Sheriff
Posts: 13411
Firefox Browser VI Editor Redhat
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
You might also want to look at the Administrator application.
It doesn't ship with the more recent versions and I'm not sure if it's even supported any more but I know it does allow you to create, and configure things like data sources, and users while Tomcat is running.

The source to this application might get you off to a good start.

You can download the Administrator application for Tomcat 5.5 from here:
http://tomcat.apache.org/download-55.cgi
[ June 28, 2008: Message edited by: Ben Souther ]
reply
    Bookmark Topic Watch Topic
  • New Topic