Re: How to share resources across two applications

2005-10-30 Thread Nihita Goel
Thanks this worked. Also copying the required files in WEB-INF gave me the sdesired security also. Regards Nihita Archana Mathur wrote: In order to access resource of other applications, you have to set parameter crossContext = "true" in context.xml file of application w1. Example - getSer

Re: How to share resources across two applications

2005-10-27 Thread David Delbecq
Hi, maybe the problem is not were we thought it was. If you get a NullPointerException a (1) (i mean not somewhere deeper inside 1 but exactly at 1), that can only mean getServletContext() returned false. This may be the case if servelt was not properly initialized. Check your init(ServletConfig co

Re: How to share resources across two applications

2005-10-27 Thread Archana Mathur
In order to access resource of other applications, you have to set parameter crossContext = "true" in context.xml file of application w1. Example - getServletContext().getContext("/w2app") will not return null, if you set this parameter. Nihita Goel wrote: Hi, I have two applications run

Re: How to share resources across two applications

2005-10-27 Thread Nihita Goel
I cannot use simple href tags in w1 application coz this application has a single controller Servlet where all requestes are received and then authenticated and other checks .. if all is well it calles the respective page. w2 application has no security restrictions as of now - I just want a

RE: How to share resources across two applications

2005-10-27 Thread Steve Kirk
Why not just include tags in your w1 webapp's pages whose href attributes point direct to URIs that begin "/w2app/" and vice-versa? I don't think you need to use dispatchers. The docs for ServletContext#getContext (your line 1) say: "...The given path must be begin with "/", is interpreted rela