I am currently running a Java web application on Tomcat 6, and have set up a virtual host in Apache HTTP Server to forward requests to the Tomcat. The context paths are therefore different. When the web app is accessed at
http://server:8080/WebApp
the context path is '/WebApp' and the context is retrieved. When accessing the same JSP via the proxy at
http://webapp/
the context path is '' and application.getContext() returns null.
Is there any configuration I might have missed when setting up the virtual host, or is this a problem with the application code?