private void addApplication( ServiceReference reference, PaxWicketApplicationFactory internalFactory) { if (!internalFactory.isValidFactory()) { LOGGER.warn( "Trying to register ApplicationFactory without application name or mount point is not possible"); return; } LOGGER.debug( "Service Added [{}], Factory hash [{}]", reference, identityHashCode(internalFactory)); Servlet servlet = ServletProxy.newServletProxy(internalFactory); addServlet( internalFactory.getMountPoint(), servlet, internalFactory.getContextParams(), reference); synchronized (factories) { factories.put(reference, internalFactory); } }