After all sites has been fully initialized and ready for snapshot, we should enable the scoreboard.
353979
boolean enableScoreboard() {
        assert (s_barrier != null);
        try {
            s_barrier.await(3L, TimeUnit.MINUTES);
        } catch (InterruptedException | BrokenBarrierException |TimeoutException e) {
            hostLog.error("Cannot re-enable the scoreboard.");
            s_barrier.reset();
            return false;
        }

        m_scoreboardEnabled = true;
        if (hostLog.isDebugEnabled()) {
            hostLog.debug("Scoreboard has been enabled.");
        }
        return true;
    }
533904
void iniSite(CmsUserSettings settings) {

        List<CmsSite> sitesList = OpenCms.getSiteManager().getAvailableSites(m_cms, false, false, m_ou.getValue());

        IndexedContainer container = new IndexedContainer();
        container.addContainerProperty("caption", String.class, "");
        CmsSite firstNoRootSite = null;
        for (CmsSite site : sitesList) {
            if (CmsStringUtil.isEmptyOrWhitespaceOnly(site.getSiteRoot())) {
                if (hasRole(CmsRole.VFS_MANAGER)
                    | ((m_user == null)
                        & m_group.getValue().equals(OpenCms.getDefaultUsers().getGroupAdministrators()))) {
                    Item item = container.addItem(site.getSiteRoot());
                    item.getItemProperty("caption").setValue(site.getTitle());
                }
            } else {
                if (firstNoRootSite == null) {
                    firstNoRootSite = site;
                }
                Item item = container.addItem(site.getSiteRoot());
                item.getItemProperty("caption").setValue(site.getTitle());
            }
        }
        if (container.size() == 0) {
            if (!container.containsId(A_CmsUI.getCmsObject().getRequestContext().getSiteRoot())) {
                Item defaultItem = container.addItem(A_CmsUI.getCmsObject().getRequestContext().getSiteRoot());
                defaultItem.getItemProperty("caption").setValue(
                    A_CmsUI.getCmsObject().getRequestContext().getSiteRoot());
            }
            m_visSites = false;
        }
        m_site.setContainerDataSource(container);
        m_site.setItemCaptionPropertyId("caption");
        m_site.setNewItemsAllowed(false);
        m_site.setNullSelectionAllowed(false);
        if (settings != null) {
            if (settings.getStartSite().length() >= 1) {
                m_site.select(settings.getStartSite().substring(0, settings.getStartSite().length() - 1));
            } else {
                LOG.error("The start site is unvalid configured");
            }
        } else {

            if (firstNoRootSite != null) {
                m_site.select(firstNoRootSite.getSiteRoot());
            } else {
                m_site.select(container.getItemIds().get(0));
            }
        }
    }
879766
void registerAppReInit() {
        // on re-init make sure GAID is available
        if (!trackingController.isTrackingDisabled()) { // Do not get GAID when tracking is disabled
            isGAParamsFetchInProgress_ = deviceInfo_.getSystemObserver().prefetchGAdsParams(context_, this);
        }
        if (networkCount_ != 0) {
            networkCount_ = 0;
            requestQueue_.clear();
        }
        ServerRequest initRequest = getInstallOrOpenRequest(null);
        if(isGAParamsFetchInProgress_) {
            initRequest.addProcessWaitLock(ServerRequest.PROCESS_WAIT_LOCK.GAID_FETCH_WAIT_LOCK);
        }
        registerInstallOrOpen(initRequest, null);
    }
1303603
function onBeforeSecurityLogin()
    {
        $site = Multisites::inst()->getCurrentSite();

        if ($site && $site->Theme) {
            SSViewer::set_themes([$site->Theme, SSViewer::DEFAULT_THEME]);
        }
    }
129672
private void initialize() {
        this.setText(Constant.messages.getString("sites.resend.popup"));

        this.addActionListener(new java.awt.event.ActionListener() { 

        	@Override
        	public void actionPerformed(java.awt.event.ActionEvent evt) {    

                if (treeSite != null) {
        		    SiteNode node = (SiteNode) treeSite.getLastSelectedPathComponent();

            	    ManualRequestEditorDialog dialog = extension.getResendDialog();
            	    HistoryReference ref = node.getHistoryReference();
            	    HttpMessage msg = null;
            	    try {
                        msg = ref.getHttpMessage().cloneRequest();
                        dialog.setMessage(msg);
                        dialog.setVisible(true);
                    } catch (HttpMalformedHeaderException | DatabaseException e) {
                        logger.error(e.getMessage(), e);
                    }
                }
        	}
        });

			
	}
256548
@Override
	@Transactional
	public synchronized void enableMonitoring() {
		requireNotDisposed();
		_logger.info("Globally enabling all system monitoring.");
		_setServiceEnabled(true);
		_checkAlertExistence(true);
		_logger.info("All system monitoring globally enabled.");
	}
118471
public void initializeFinished() {

        if (CmsLog.INIT.isInfoEnabled()) {
            CmsLog.INIT.info(Messages.get().getBundle().key(Messages.INIT_VFS_CONFIG_FINISHED_0));
        }
    }
675503
@PostConstruct
    public synchronized void initialize() {
        final FwWebDirection direction = assistWebDirection();
        final DoubleSubmitResourceProvider provider = direction.assistDoubleSubmitResourceProvider();
        allowsVerifyTokenBeforeValidation = provider != null && provider.allowsVerifyTokenBeforeValidation();
        showBootLogging();
    }
351698
private void initBuildScoreChildrenSettings(BuildScoreSettings buildScoreSettings) {
    ScoreComponentSettings buildStatusSettings = Utils.getInstanceIfNull(
      buildScoreSettings.getStatus(),
      ScoreComponentSettings.class
    );
    buildStatusSettings.setCriteria(
      Utils.mergeCriteria(buildScoreSettings.getCriteria(), buildStatusSettings.getCriteria())
    );
    buildScoreSettings.setStatus(buildStatusSettings);

    BuildScoreSettings.BuildDurationScoreSettings buildDurationSettings = Utils.getInstanceIfNull(
      buildScoreSettings.getDuration(),
      BuildScoreSettings.BuildDurationScoreSettings.class
    );

    buildDurationSettings.setCriteria(
      Utils.mergeCriteria(buildScoreSettings.getCriteria(), buildDurationSettings.getCriteria())
    );
    buildScoreSettings.setDuration(buildDurationSettings);
  }
1115679
private void onUploadFinished() {
        if (artifactUploadState.areAllUploadsFinished() && artifactUploadState.isStatusPopupMinimized()) {
            if (artifactUploadState.getFilesInFailedState().isEmpty()) {
                cleanupStates();
                closeWindow();
            } else {
                maximizeWindow();
            }
        }
    }
557844
protected function setUp(): void
    {
        parent::setUp();

        if ($this->hasReturnType()) {
            $this->getFile()->recordMetric($this->stackPos, 'Has return type', 'yes');
        }
    }
170676
public void startMonitoring() {
        if (debug) LogD("");
        long start = settings.getLong(KEY_MONITOR_START, 0);
        if (start != 0) {
            if (debug) LogD("Monitor error.  called before end. Adding the result");
            endMonitoring();
        }
        editor.putLong(KEY_MONITOR_START, System.currentTimeMillis());
        commitEditor();
    }
367520
public static function enableMaintenanceMode()
    {
        $config = Config::getInstance();

        $tracker = $config->Tracker;
        $tracker['record_statistics'] = 0;
        $config->Tracker = $tracker;

        $general = $config->General;
        $general['maintenance_mode'] = 1;
        $config->General = $general;

        $config->forceSave();
    }
1348071
@PostConstruct
    public synchronized void initialize() {
        BowgunCurtainBefore.unlock();
        BowgunCurtainBefore.shootBowgunCurtainBefore(assistantDirector -> {
            if (!bowgunEmptyScheduling) { // for e.g. UnitTest
                startSchedule();
            }
            showBootLogging();
        });
    }
1156796
protected function initialiseMonitoring()
    {
        for ($i = 0; $i < count($this->entries); $i++) {
            $this->monitor->monitor($this->entries[$i]['entry']);
        }
    }
708058
public function markSuccess()
    {
        if ($this->stateStorage->isCircuitOpen($this->commandKey)) {
            $this->stateStorage->closeCircuit($this->commandKey);
            // may cause some stats to be removed from reporting, see http://goo.gl/dtHN34
            $this->metrics->resetCounter();
        }
    }
724039
public void onInitialDataDownloaded() {
        Log.d(TAG, "Initial Data Loaded");
        context().getContactsModule().startImport();
        if (appStateVM.isBookImported()) {
            onAppLoaded();
        }
    }