Shuts down all module instance classes managed in this module manager.<p>
173070
public synchronized void shutDown() {

        int count = 0;
        Iterator<String> it = getModuleNames().iterator();
        while (it.hasNext()) {
            String moduleName = it.next();
            // get the module
            CmsModule module = m_modules.get(moduleName);
            if (module == null) {
                continue;
            }
            // get the module action instance
            I_CmsModuleAction moduleAction = module.getActionInstance();
            if (moduleAction == null) {
                continue;
            }

            count++;
            if (CmsLog.INIT.isInfoEnabled()) {
                CmsLog.INIT.info(
                    Messages.get().getBundle().key(
                        Messages.INIT_SHUTDOWN_MOD_CLASS_1,
                        moduleAction.getClass().getName()));
            }
            try {
                // shut down the module
                moduleAction.shutDown(module);
            } catch (Throwable t) {
                LOG.error(
                    Messages.get().getBundle().key(
                        Messages.LOG_INSTANCE_SHUTDOWN_ERR_1,
                        moduleAction.getClass().getName()),
                    t);
            }
        }

        if (CmsLog.INIT.isInfoEnabled()) {
            CmsLog.INIT.info(
                Messages.get().getBundle().key(Messages.INIT_SHUTDOWN_NUM_MOD_CLASSES_1, new Integer(count)));
        }

        if (CmsLog.INIT.isInfoEnabled()) {
            CmsLog.INIT.info(Messages.get().getBundle().key(Messages.INIT_SHUTDOWN_1, this.getClass().getName()));
        }
    }
1205908
void close() {

        try {
            clearLock();
            m_context.finish(Collections.singletonList(m_resource.getStructureId()));
        } catch (CmsException e) {
            m_context.error(e);
        }
    }
82136
public void deactivateAll() {

        for (Widget button : getAll()) {
            if (button instanceof I_CmsToolbarActivatable) {
                ((I_CmsToolbarActivatable)button).setEnabled(false);
            } else if (button instanceof CmsToggleButton) {
                ((CmsToggleButton)button).setEnabled(false);
            }
        }
    }
678717
@SuppressWarnings("rawtypes")
    @Override
    public void destroy() {
        for (List<Handler> handlers : this.handlersMap.values()) {
            for (Handler handler : handlers) {
                try {
                    clientMetaData.getModuleMetaData().getJaxWsInstanceManager().destroyInstance(handler);
                } catch (InterceptException e) {
                    throw new WebServiceException(e);
                }
            }
        }
    }
555574
public void shutdown() {
        try {
            LOGGER.info("Shutting down Hazelcast instance [{}]", this.hazelcastInstance.getConfig().getInstanceName());
            this.hazelcastInstance.shutdown();
        } catch (final Exception e) {
            LOGGER.debug(e.getMessage());
        }
    }
915430
public static void shutdownAll() {
		for (final ExecutorService executor : new ArrayList<ExecutorService>(BACKGROUND_EXECUTORS)) {
			shutdown(executor);
			BACKGROUND_EXECUTORS.remove(executor);
		}
		for (final ScheduledExecutorService scheduler : new ArrayList<ScheduledExecutorService>(SCHEDULERS)) {
			shutdown(scheduler);
			SCHEDULERS.remove(scheduler);
		}
	}
710242
public synchronized void shutDown() {

        m_adminCms = null;

        if (CmsLog.INIT.isInfoEnabled()) {
            CmsLog.INIT.info(Messages.get().getBundle().key(Messages.INIT_SHUTDOWN_1, this.getClass().getName()));
        }

        if (m_scheduler != null) {
            try {
                m_scheduler.shutdown();
            } catch (SchedulerException e) {
                LOG.error(Messages.get().getBundle().key(Messages.LOG_SHUTDOWN_ERROR_0));
            }
        }

        m_scheduler = null;
    }
1004704
public void shutdown() {
        for (Connection connection : _connectionMap.values()) {
            connection.shutdown();
        }

        for (Connection connection : _privilegedConnectionMap.values()) {
            connection.shutdown();
        }

        _factory.releaseExternalResources();
    }
637961
void closeAllScopeModules() {
        synchronized (puScopes) {
            for (String module : puScopes.keySet()) {
                close(module, false); //PK59717
            }
            puScopes.clear();
        }
    }
60042
@Override
    public void shutdown()
    {
        if (manager != null)
        {
            manager.removalAll();
            manager = null;
        }
        cache = null;
    }
364484
public void stopModule(ExtendedModuleInfo moduleInfo) {
        
        if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled()) {
            Tr.entry(tc, "stopModule()",((WebModuleInfo)moduleInfo).getName());
        }
       
        WebModuleInfo webModule = (WebModuleInfo) moduleInfo;
        try {
            DeployedModule dMod = this.deployedModuleMap.remove(webModule);
            if (null == dMod) {
                if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled()) {
                    Tr.exit(tc, "stopModule()","DeployedModule not known");
                }
                return;
            }
            
            if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled()) {
                Tr.debug(tc, "stopModule: " + webModule.getName() + " " + webModule.getContextRoot());
            }

            removeContextRootRequirement(dMod);
            removeModule(dMod);
            
            this.vhostManager.purgeHost(dMod.getVirtualHostName());

            WebModuleMetaData wmmd = (WebModuleMetaData) ((ExtendedModuleInfo)webModule).getMetaData();
            
            deregisterMBeans((WebModuleMetaDataImpl) wmmd);
            
            WebAppConfiguration appConfig = (WebAppConfiguration) wmmd.getConfiguration();
            for (Iterator<IServletConfig> servletConfigs = appConfig.getServletInfos(); servletConfigs.hasNext();) {
                IServletConfig servletConfig = servletConfigs.next();
                metaDataService.fireComponentMetaDataDestroyed(servletConfig.getMetaData());
            }

            metaDataService.fireComponentMetaDataDestroyed(appConfig.getDefaultComponentMetaData());
            metaDataService.fireComponentMetaDataDestroyed(wmmd.getCollaboratorComponentMetaData());
        } catch (Throwable e) {
            FFDCWrapper.processException(e, getClass().getName(), "stopModule", new Object[] { webModule, this });
            if (TraceComponent.isAnyTracingEnabled() && tc.isEventEnabled()) {
                Tr.event(tc, "stopModule: " + webModule.getName() + "; " + e);
            }
        }
        if (TraceComponent.isAnyTracingEnabled() && tc.isEntryEnabled()) {
            Tr.exit(tc, "stopModule()");
        }

    }
514066
private void shutdown(String applicationName, ClassLoader classLoader) {
        synchronized (configCache) {
            ConfigWrapper configWrapper = configCache.get(classLoader);
            boolean close = configWrapper.removeApplication(applicationName);
            if (close) {
                close(classLoader);
            }
        }
    }
1096832
public void clearRegisteredModules()
    {
        ServletContext servletContext = getServletContext();
        
        for ( Iterator ii = _registeredModules.keySet().iterator(); ii.hasNext(); )  
        {
            String modulePrefix = ( String ) ii.next();
            servletContext.removeAttribute( Globals.MODULE_KEY + modulePrefix );
            servletContext.removeAttribute( Globals.REQUEST_PROCESSOR_KEY + modulePrefix );
        }
        
        _registeredModules.clear();
    }
955995
@Override
    public void destroyApplicationScopeResources(JaxRsModuleMetaData jaxRsModuleMetaData) {

        for (ModuleMetaData mmd : jaxRsModuleMetaData.getEnclosingModuleMetaDatas()) {
            managedObjectFactoryCache.remove(mmd);
            Iterator<ComponentMetaData> iter = beanManagers.keySet().iterator();
            while (iter.hasNext()) {
                ComponentMetaData cmd = iter.next();
                if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled()) {
                    Tr.debug(tc, "destroyApplicationScopeResources - is " + cmd + " a child of " + mmd + "?");
                }

                if (mmd.equals(cmd.getModuleMetaData())) {
                    if (TraceComponent.isAnyTracingEnabled() && tc.isDebugEnabled()) {
                        Tr.debug(tc, "destroyApplicationScopeResources - yes");
                    }
                    iter.remove();
                }
            }
        }
        Bus bus = jaxRsModuleMetaData.getServerMetaData().getServerBus();

        @SuppressWarnings("unchecked")
        Map<String, BeanCustomizerContext> beanCustomizerContexts = (Map<String, BeanCustomizerContext>) bus.getProperty(JaxRsConstants.ENDPOINT_BEANCUSTOMIZER_CONTEXTOBJ);
        if (beanCustomizerContexts == null) {
            return;
        }
        @SuppressWarnings("unchecked")
        Map<Class<?>, ManagedObject<?>> newContext = (Map<Class<?>, ManagedObject<?>>) beanCustomizerContexts.get(createCustomizerKey(this));
        if (newContext == null) {
            return;
        }
        Collection<ManagedObject<?>> objects = newContext.values();
        for (ManagedObject<?> mo : objects) {

            if (mo != null) {
                mo.release();
            }
        }

//destroy application
        ManagedObject<?> appObject = (ManagedObject<?>) jaxRsModuleMetaData.getManagedAppRef();
        if (appObject != null) {
            appObject.release();
        }
    }
851556
private void stop(ShutdownModeAmp mode)
  {
    _shutdownMode = mode;
    
    Thread thread = Thread.currentThread();
    ClassLoader oldLoader = thread.getContextClassLoader();

    try {
      thread.setContextClassLoader(_classLoader);

      if (! _lifecycle.toStopping()) {
        return;
      }

      TreeSet<SubSystem> systems
        = new TreeSet<SubSystem>(new StopComparator());

      systems.addAll(_systemMap.values());

      // sort

      for (SubSystem system : systems) {
        try {
          thread.setContextClassLoader(_classLoader);

          if (log.isLoggable(Level.FINEST)) {
            log.finest(system + " stopping");
          }

          system.stop(mode);
        } catch (Throwable e) {
          log.log(Level.WARNING, e.toString(), e);
        }
      }

    } finally {
      _lifecycle.toStop();

      thread.setContextClassLoader(oldLoader);
    }
  }
192266
public void shutdown() {
		synchronized (globalLock) {
			for (Instance i : allInstances) {
				i.removeSlotListener();
				i.cancelAndReleaseAllSlots();
			}
			allInstances.clear();
			allInstancesByHost.clear();
			instancesWithAvailableResources.clear();
			taskQueue.clear();
		}
	}
177289
public void shutdown() {
		Iterator<ExclusionFilterFactory> itr = factories.iterator();
		while (itr.hasNext()) {
			ExclusionFilterFactory i = itr.next();
			i.shutdown();
		}
	}