public static void removeService(NamingContextListener namingContextListener, String serviceName) { getAPI().removeService(namingContextListener, serviceName); }
public TomcatJndiBuilder(StandardContext standardContext, WebAppInfo webAppInfo, Collection<Injection> injections) { this.injections = injections; this.standardContext = standardContext; this.namingContextListener = BackportUtil.getNamingContextListener(standardContext); this.webAppInfo = webAppInfo; String parameter = standardContext.findParameter("openejb.start.late"); replaceEntry = Boolean.parseBoolean(parameter); }
String serviceName = BackportUtil.findServiceName(naming, ref.referenceName.replaceAll("^comp/env/", "")); if (serviceName != null) { ContextAccessController.setWritable(namingContextListener.getName(), standardContext); if (!addEntry) BackportUtil.removeService(namingContextListener, serviceName); ContextAccessController.setReadOnly(namingContextListener.getName());
if (getServlet(wrapper) != null) { wrapper.load(); wrapper.unload();
public static Servlet getServlet(Wrapper wrapper) { return getAPI().getServlet(wrapper); }
NamingContextListener ncl = getNamingContextListener(standardContext); String listenerName = ncl.getName(); ContextAccessController.setWritable(listenerName, standardContext);
public static String findServiceName(NamingResources naming, String refName) { return getAPI().findServiceName(naming, refName); }
public static NamingContextListener getNamingContextListener(StandardContext standardContext) { return getAPI().getNamingContextListener(standardContext); }
File contextXmlFile = new File(standardContext.getDocBase() + s + "META-INF" + s + "context.xml"); if (contextXmlFile.exists()) { BackportUtil.getAPI().setConfigFile(standardContext, contextXmlFile); standardContext.setOverride(true);