第七色在线视频,2021少妇久久久久久久久久,亚洲欧洲精品成人久久av18,亚洲国产精品特色大片观看完整版,孙宇晨将参加特朗普的晚宴

為了賬號(hào)安全,請(qǐng)及時(shí)綁定郵箱和手機(jī)立即綁定
已解決430363個(gè)問題,去搜搜看,總會(huì)有你想問的

重新啟動(dòng)(回收)應(yīng)用程序池

重新啟動(dòng)(回收)應(yīng)用程序池

ibeautiful 2019-08-12 11:32:06
重新啟動(dòng)(回收)應(yīng)用程序池如何從C#(.net 2)重新啟動(dòng)(回收)IIS應(yīng)用程序池?感謝您發(fā)布示例代碼嗎?
查看完整描述

3 回答

?
慕后森

TA貢獻(xiàn)1802條經(jīng)驗(yàn) 獲得超5個(gè)贊

如果您使用的是IIS7,那么如果它已停止,則會(huì)執(zhí)行此操作。我假設(shè)你可以調(diào)整重啟而不必顯示。

// Gets the application pool collection from the server.[ModuleServiceMethod(PassThrough = true)]public ArrayList GetApplicationPoolCollection(){
    // Use an ArrayList to transfer objects to the client.
    ArrayList arrayOfApplicationBags = new ArrayList();

    ServerManager serverManager = new ServerManager();
    ApplicationPoolCollection applicationPoolCollection = serverManager.ApplicationPools;
    foreach (ApplicationPool applicationPool in applicationPoolCollection)
    {
        PropertyBag applicationPoolBag = new PropertyBag();
        applicationPoolBag[ServerManagerDemoGlobals.ApplicationPoolArray] = applicationPool;
        arrayOfApplicationBags.Add(applicationPoolBag);
        // If the applicationPool is stopped, restart it.
        if (applicationPool.State == ObjectState.Stopped)
        {
            applicationPool.Start();
        }

    }

    // CommitChanges to persist the changes to the ApplicationHost.config.
    serverManager.CommitChanges();
    return arrayOfApplicationBags;}

如果您使用的是IIS6,我不太確定,但您可以嘗試獲取web.config并編輯修改日期或其他內(nèi)容。對(duì)web.config進(jìn)行編輯后,應(yīng)用程序?qū)⒅匦聠?dòng)。


查看完整回答
反對(duì) 回復(fù) 2019-08-12
?
繁華開滿天機(jī)

TA貢獻(xiàn)1816條經(jīng)驗(yàn) 獲得超4個(gè)贊

開始了:

HttpRuntime.UnloadAppDomain();


查看完整回答
反對(duì) 回復(fù) 2019-08-12
  • 3 回答
  • 0 關(guān)注
  • 771 瀏覽

添加回答

舉報(bào)

0/150
提交
取消
微信客服

購(gòu)課補(bǔ)貼
聯(lián)系客服咨詢優(yōu)惠詳情

幫助反饋 APP下載

慕課網(wǎng)APP
您的移動(dòng)學(xué)習(xí)伙伴

公眾號(hào)

掃描二維碼
關(guān)注慕課網(wǎng)微信公眾號(hào)