Java Mailing List Archive

http://www.junlu.com/

Home » Home (12/2007) » Tomcat Users »

crossContext="true" ignored after restart

Tony Tomcat

2005-02-18


After my war file is reloaded I can no longer access other webapp context's.  

Simple test.jsp follows. It prints "everything is fine" 1st time war
file is deployed. If I rebuild the war file and it is auto reloaded I
get "cross context failed".

test,jsp  (does not live in /)
<%

ServletContext testContext = getServletContext();

if (testContext == null) {
out.println("basic context get failed");
} else {
ServletContext crossContext = testContext.getContext("/");
if (crossContext == null)
  out.println("cross context failed");
else {
  out.println("everything is fine");
}
}
%>

Any ideas here?
Tony

---------------------------------------------------------------------
To unsubscribe, e-mail: tomcat-user-unsubscribe@(protected)
For additional commands, e-mail: tomcat-user-help@(protected)

©2008 junlu.com - Jax Systems, LLC, U.S.A.