cancel
Showing results for 
Search instead for 
Did you mean: 

Fully Virtualized Application

rdanner
Champ in-the-making
Champ in-the-making
I'd like to know who out there is really using the virtualization platform to virtual j2EE applications – if so what type of application, and what technology is it built on.

I'd also like to get a discussion going here about best practices when it comes to managing applications inside a web project.   Do we have people who would be interested in that? 



If you are here are a couple of things you might like to know:

* In order to give the virtualization server access to resources inside the war (when .getRealPath() is called) you will need to have the V: drive mounted. (windows).  This applies to spring context files for example.

*  ServletContext.getRealPath() returns a path to the staging sandbox – not the sandbox you are working in – watch out for this bug – it will drive you mad unless you catch it early on.  either patch the code or use request.getRealPath() instead.
1 REPLY 1

rdanner
Champ in-the-making
Champ in-the-making
I'd like to know who out there is really using the virtualization platform to virtual j2EE applications – if so what type of application, and what technology is it built on.

I'd also like to get a discussion going here about best practices when it comes to managing applications inside a web project.   Do we have people who would be interested in that? 



If you are here are a couple of things you might like to know:

* In order to give the virtualization server access to resources inside the war (when .getRealPath() is called) you will need to have the V: drive mounted. (windows).  This applies to spring context files for example.

*  ServletContext.getRealPath() returns a path to the staging sandbox – not the sandbox you are working in – watch out for this bug – it will drive you mad unless you catch it early on.  either patch the code or use request.getRealPath() instead.


Thought everyone might like to know that I was incorrect about the ServletContext.getRealPath() bug – it turns out something I am doing in my application does not play well with the virtualization server.

The simple test case of a single JSP application with the following body:



<%=this.getServletContext().getRealPath("/") %><br/>
<%=request.getRealPath("/") %><br/>

produces the correct and expected output


v:\simple–admin\VERSION\v-1\DATA\www\avm_webapps\ROOT\
v:\simple–admin\VERSION\v-1\DATA\www\avm_webapps\ROOT\

VirtServer 1 : Russ 0 :lol:

Sorry about the misinformation  Smiley Surprisedops:

Now… gotta go fix that bug in my app  :shock:

There is one other test I want to run which is an actual servlet loaded by the Web.xml  … it's a little different than a JSP but I don't expect a different result – but it would unwise to leave the final test case uncovered.