Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

servlet mapping doubt from MKZ notes.. Please help me understand..

 
Vishal Chugh
Ranch Hand
Posts: 177
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello Ranchers ,

I am going through Mikalai notes these days:

I came across below lines and got confused , please help me understanding below lines:

In the Web application deployment descriptor, the following syntax is used to define mappings:

1)A string beginning with a '/' character and ending with a '/*' suffix is used for path mapping.

2)A string beginning with a '*.' prefix is used as an extension mapping.

3)A string containing only the '/' character indicates the "default" servlet of the application. In this case
the servlet path is the request URI minus the context path and the path info is null.

4)All other strings are used for exact matches only.


I am okay with (1) and (2) but confused about (3) and (4) , Someone please elaborate more on 3 and 4 ...

[Actually i am not able to go through detailed specs ,I know Mikalai notes are from spec covering all relevent so cant skip any concept , may be what i skip will catch me in exam :roll: ]

Thanks in advance..
Vishal Chugh



 
Vishal Chugh
Ranch Hand
Posts: 177
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
and also below :

Request_URI = Context_Path [1] + Servlet_Path [2] + Path_Info [3] + Query_String [4]
http://server.com/my_app_context[1]/catalog[2]/product[3]?mode=view[4]
Context path.

Specifies the path prefix associated with a web application mapping.
For a default application (rooted at the
base of the web server's URL namespace), the context path is an empty string.


what is default application ?
How it looks like and
how can an application exist without context-root (when they say context path is empty string ) ?
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic