@Override public EJBClientContext getCurrent() { final ClassLoader tccl = SecurityActions.getContextClassLoader(); // TODO: Do we fall back on some other CL? if (tccl == null) { throw EjbMessages.MESSAGES.tcclNotAvailable(); } synchronized (this.ejbClientContexts) { return this.ejbClientContexts.get(tccl); } }
@Override public EJBClientContext getCurrent() { if (this.tcclEJBClientContextService == null) { return null; } final EJBClientContext ejbClientContext = this.tcclEJBClientContextService.getCurrent(); if (ejbClientContext != null) { return ejbClientContext; } // explicit isDebugEnabled() check to ensure that the SecurityActions.getContextClassLoader() isn't // unnecessarily executed when debug logging is disabled if (logger.isDebugEnabled()) { logger.debug("Returning default EJB client context " + this.defaultEJBClientContext + " since no EJB client context could be found for TCCL " + SecurityActions.getContextClassLoader()); } return this.defaultEJBClientContext; }
Class<?> viewClass; try { viewClass = Class.forName(this.viewClass, false, SecurityActions.getContextClassLoader()); } catch (ClassNotFoundException e) { if(viewClassLoader == null || viewClassLoader.getValue() == null) {