Win a copy of The Business Blockchain this week in the Cloud forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

How do servlet mapping in web.xml that the path information is not lost

 
Anoop Krishnan
Ranch Hand
Posts: 163
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In my spring application I am using SiteMesh also.

I have a servlet mapping (web.xml) as given below for my dispatcher servlet


The site mesh filter is configured as given below


The decorator file for the site mesh contains the following mapping


The problem is when I use a URL with /excellink/screener/a.view It doesn't reach to the site mesh file which is excelScreenerShell.jsp.
but if I use a URL /screener/a.view it works !!!

That means the servlet mapping for NgpServlet removes the path /excellink

Is there any way to fix this with out touching the servlet mapping or changing the map in the decorator file ?

 
Leonardo Carreira
Ranch Hand
Posts: 494
Eclipse IDE Java Postgres Database
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Anoop..

How about if you configure your Dispatcher Servlet like this :


try to remove "excellink"..
please correct me if i'm wrong..

 
Anoop Krishnan
Ranch Hand
Posts: 163
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Leonardo ,
Thank you for taking time to look in to my problem.
I know this solution already but this will break another application

I am just looking for a solution in web.xml with out changing the existing mappings
 
Bear Bibeault
Author and ninkuma
Marshal
Pie
Posts: 65335
97
IntelliJ IDE Java jQuery Mac Mac OS X
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Leonardo Carreira wrote:How about if you configure your Dispatcher Servlet like this :

mapping "/*" is never a good idea. That means that all requests, including those to images, CSS files, JavaScript files, JSP files and so one will be routed to the servlet.
 
Leonardo Carreira
Ranch Hand
Posts: 494
Eclipse IDE Java Postgres Database
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Oops sorry..

Thanks Bear for your attention..
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic