try {
if(_instance == null) {
String proxyClassName = "com.sun.enterprise.server.ss.ASSocketServiceProxy";
Class socketServiceProxy = null;
/* If the new classloader hierachy is switched on, use appserver-chain to load
the class */
if(Boolean.getBoolean(PELaunch.USE_NEW_CLASSLOADER_PROPERTY)) {
socketServiceProxy = PELaunch.getAppServerChain().loadClass(proxyClassName);
} else {
socketServiceProxy = ASSocketFacadeUtils.class.getClassLoader().loadClass(proxyClassName);
}
_instance = (ASSocketServiceFacade)socketServiceProxy.newInstance();
}
return _instance;
} catch (Exception e) {
RuntimeException rte = new RuntimeException(e.getMessage());
rte.initCause(e);
throw rte;
}