tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
Subject Re: which classes to use to modify server.xml
Date Tue, 14 Mar 2000 19:32:42 GMT
> 	Looked into the 3.1 beta RC1 version. saw the context admin interface.
> NOW: When i add a context using this interface, it doesn't modify
> "server.xml". Ideally, shouldn't it be adding a <context></context>

Yes, but it does add the context to the running server without restart.

About saving to server.xml - it is not implemented, and it should be
independent of the admin interface. 
server.xml is not the only config system, and you want to have everything
working if you use LDAP for configuration or any other native application

Check ContextInterceptor - it gets notifications when contexts are added,
you can implement persistence there ( i.e. an adapter for your config
system, we should provide a default one for server.xml )

> My questions are:
> 1) How is tomcat getting in the context "bank" when there is no entry in
> server.xml. Is it because tomcat "picks" the contexts from "webapp"
> directory rather than server.xml or am i missing something? Has
> "server.xml" been deprecated?  :) :)

No. Configuring via server.xml is easy, integrating with other
applications is hard - we don't want to force server.xml ( and I don't
think the format of server.xml was designed well enough or we had
feedback - so don't assume it's final !) 

We have a small interceptor that reads webapps/ and add them automatically
at startup. You can create other interceptors to implement other policies,
or just disable webapps and set up everything in config files.

> 2) Do i have to copy the WAR file into "c:\program files\apache
> group\jakarta-tomcat\webapps\" to use the Context Admin interface to add
> new contexts?

No, the context can be anywhere.

webapps/ are added automatically at startup.

> In case of any small prob.s/improvements with Context Admin, may be i
> can fix/make them(if none is working on it at present).

Please do so! Let me know if you need help.


View raw message