Application Server Solutions for Microsoft IIS and ASP.NET
       solutions   products   partners   company   support   downloads         store
ServletExec Self-Help: FAQ
Back to Search >  Back to Search Results

Faq ID 113
Product ServletExec
Category Virtual Server
Question I'm running SE in a virtual server environment. When I request a JSP from one virtual server, sometimes I get a JSP from the other virtual server instead of the one that I expected. What is wrong?
Answer This problem does not occur when using a Web Application.
It only occurs if you are running your JSPs as "Legacy" (i.e. non-webapp).
When this problem occurs, it is likely that the 2 JSPs have the same name. If things are not configured correctly, JSP files generated for one virtual server can overwrite the files generated by another virtual server. Anytime you are running ServletExec with multiple Virtual Servers you must make certain that ServletExec is creating and using a separate pagecompile folder for each virtual server. This way JSPs that execute for each virtual server will be the correct and expected versions for that virtual server.

If your virtual servers are distinguished by host name:
  • Then you would accomplish this by using the ServletExec Admin UI to add a Virtual Server for the 2nd, 3rd, ...etc host names and specify a unique Servlets folder for each. This will stop the generated servlet files from overwriting each other since each virtual server will have its own separate Servlets directory (and therefore its own separate pagecompile directory).
If your virtual servers are distinguished by port number:
  • Then configure the JSP10Servlet with the init argument packageLevel set to 1. This will cause the JSP10Servlet to add additional levels to the package used by the generated servlet files. This will cause the generated files to have unique package names and to be placed into unique directories beneath the Servlets directory.
If you continue to have problems with Legacy JSPs in a virtual server environment then you should verify that the generated files for each virtual server are being placed in separate directories and not in the same directory where they could overwrite each other.
Note: The best way to ensure that the JSP pages generated for each virtual server have a unique class name is to use Web Applications exclusively.

company media information terms of use privacy policy contact us