From: <glassfish_at_javadesktop.org>
Date: Tue, 11 Nov 2008 11:33:10 PST
I will defer to someone else why in your latest attempt to use InitialContext() without parameters does not work.
Here is another suggestion to make the code more portable.
WebSphere provides a way to pass properties to InitialContext in a jndi.properties and including that in the classpath first. From the websphere documentation, it is not clear exactly how one would one would do this if a component is running on a container. Assuming this is possible, this would remove WebSphere specific code making it more portable.