2009-12-01 65 views
0

我已經建立了Velocity分佈式緩存的sesion管理。我有3個服務器託管緩存並創建了爲什麼Velocity在幾分鐘後失去會話?

new-cache Sessions -Secondaries 1 TTL 1440 

命名緩存,以下是我的web.config文件

<section name="dataCacheClient" 
type="Microsoft.Data.Caching.DataCacheClientSection,&#xD;&#xA; cacheBaseLibrary" 
allowLocation="true" 
allowDefinition="Everywhere"/> 

    <sessionState mode="Custom" customProvider="Velocity" > 
     <providers> 
      <add 
       name="Velocity" 
         type="Microsoft.Data.Caching.DataCacheSessionStoreProvider" 
       cacheName="Sessions"/> 
     </providers> 
    </sessionState> 

任何幫助,將不勝感激。

回答

1

看起來像是被驅逐出境。默認情況下,緩存是可驅逐的,即存儲在緩存中的項目可以被驅逐。您應該使用new-cache命令創建一個不可驅逐的緩存。 示例: 新緩存 - 無限無

根據需要設置其他緩存屬性。

相關問題