Experts,

I have test with success loadbalancing with tomcat, my config was:
1 apache to serve static pages
2 TC with two webapp folders
my webapp use struts 1.0.2...
this configuration works fine

Now I want to use only one webapp folder. The problem is that I want to use two different struts-config.xml depend on which TC I start, indeed, in order to define separate logfiles i.e. logstruts1.log for TC1, logstruts2.log for TC2 etc... using previously iPlanet, I used to amend servlet.properties to define which struts-config to use... What I've already done is to move my webapp web.xml to $CATALINA_BASE/conf and try to start TC... the catalina.out seems to be ok but the TC logger show me an error :

2007-07-16 16:38:43 StandardContext[]action: Initializing configuration from resource path /WEB-INF/struts-config_1.xml
2007-07-16 16:38:48 StandardContext[]action: null
java.lang.IllegalArgumentException: InputStream cannot be null
   at javax.xml.parsers.SAXParser.parse(Unknown Source)
   at org.apache.struts.digester.Digester.parse(Digester.java:755)
at org.apache.struts.action.ActionServlet.initServlet(ActionServlet.java:1434)
   at org.apache.struts.action.ActionServlet.init(ActionServlet.java:474)
at com.slb.sema.helios.fwk.action.ActionServlet.init(ActionServlet.java:123)
   at javax.servlet.GenericServlet.init(GenericServlet.java:211)
at org.apache.catalina.core.StandardWrapper.loadServlet(StandardWrapper.java:1029) at org.apache.catalina.core.StandardWrapper.load(StandardWrapper.java:862) at org.apache.catalina.core.StandardContext.loadOnStartup(StandardContext.java:4013) at org.apache.catalina.core.StandardContext.start(StandardContext.java:4357) at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1083)
   at org.apache.catalina.core.StandardHost.start(StandardHost.java:789)
at org.apache.catalina.core.ContainerBase.start(ContainerBase.java:1083) at org.apache.catalina.core.StandardEngine.start(StandardEngine.java:478) at org.apache.catalina.core.StandardService.start(StandardService.java:480) at org.apache.catalina.core.StandardServer.start(StandardServer.java:2313)
   at org.apache.catalina.startup.Catalina.start(Catalina.java:556)
   at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:85) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:58) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:60)
   at java.lang.reflect.Method.invoke(Method.java:391)
   at org.apache.catalina.startup.Bootstrap.start(Bootstrap.java:287)
   at org.apache.catalina.startup.Bootstrap.main(Bootstrap.java:425)

2007-07-16 16:38:48 StandardContext[]action: Mapping for servlet 'action' = 'null'

I finally find out how to solve this problem: copy the servlet mapping definition to my webapp web.xml.

The question is : why isn't it possible to define my servlet and its mapping in the same web.xml e.g. $CATALINA_BASE/conf/web.xml ?? is it an bug ?? or if not can someone explain me why ?

Regards,
Phi-Long LE




---------------------------------------------------------------------
To start a new topic, e-mail: users@tomcat.apache.org
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to