Thanks for your note.
web.xml for my application has clearly
bound a set of <init-parm>'s with a servlet
class. Hence the container must be able to
uniquely determine the set of initial parameters,
given a servlet class file, regardless of by what name
("default" or otherwise) the servlet is invoked.
Then why should I specify a servlet mapping?
Is this spelt out in the spec? I did not find this in
Ch13 of the 2.3 draft (I'm using Tomcat 4.0).
Rk
x77309
From: Bo Xu [mailto:[EMAIL PROTECTED]]
Sent: Monday, February 26, 2001 3:06 PM
Hi :-) I am not sure, from several emails and my understanding:
* every sevlet defination(<servlet></servlet>) will use one instance
of MyServlet, if we invoke MyServlet without
servlet-mapping(<servlet-mapping></servlet-mapping>), it means
now we want to use a "default" sevlet defination.
* every group of init-param(<init-param></init-param>) belong to
one special sevlet defination(but I guess the "default" sevlet
defination
can ont has any initParameter->null).
* from the viewing of client's invoking, how can we let Servlet container
know that which sevlet defination we want to use? I guess the only
way is use servlet-mapping(if we don't use the "default"
servlet-mapping,
i.e., we use http://host:8080/myapp/servlet/MyServlet to invoke, ,
now
it means we want to use the "default" sevlet defination) .
* so I think at least servlet-mapping has two usages:
- for user convenience
- we use it to distinguish this servlet defination and that
servlet defination, Then we can distinguish this group.
of init-param and that group of init-param
* in a short word, because:
- init-param has relation with servlet defination
- servlet-mapping also has relation with servlet defination
So init-param has relation with servlet-mapping
I just know it this afternoon :-) because I use winnt40,
and I omit the difference between "WEB-INF" and "Web-inf" :-)
so MyServlet can not read my web.xml in "Web-inf" :-)
I spent several hours, and finally I correct Web-inf to
WEB-INF... but After modifing, in the "File Manager" of winnt40,
it Still looks like "Web-inf"... //hahahahaha :-) :-)
Bo
Feb.26, 2001
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, email: [EMAIL PROTECTED]