![]() | |
![]() |
| | Thread Tools | Search this Thread | Display Modes |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
I'm caching aspx pages and ascx controls as well as programmatically within aspx code for my asp.net web application. I'd like to have a special admin aspx page that will display the contents of the cache. I'm using the IDictionaryEnumerator, see code snippet below, but this just gets me the value or data type and the key of the items entered programmatically. Here's the question. I'd like more information, such as when it was added and when it will expire, also, what pages and controls are in the cache and when they will expire. How do I do this? .......... If nCacheCount > 0 Then Dim CacheEnum As IDictionaryEnumerator = Cache.GetEnumerator() While CacheEnum.MoveNext() drCache = dtCache.NewRow() drCache("name") = CacheEnum.Key drCache("value") = CacheEnum.Current.Value.ToString() drCache("na") = "" dtCache.Rows.Add(drCache) End While ............... thanks, -phil |
#3
| |||
| |||
|
|
that info isn't exposed to the outside world because of the dictionary implementation. what you see is exactly what you get. -- Regards, Alvin Bruney - ASP.NET MVP [Shameless Author Plug] The Microsoft Office Web Components Black Book with .NET Now available @ www.lulu.com/owc "vbphil" <vbphil (AT) online (DOT) nospam> wrote in message news 76C01F6-BDBF-45E5-BECB-A5BC34AC28B7 (AT) microsoft (DOT) com...I'm caching aspx pages and ascx controls as well as programmatically within aspx code for my asp.net web application. I'd like to have a special admin aspx page that will display the contents of the cache. I'm using the IDictionaryEnumerator, see code snippet below, but this just gets me the value or data type and the key of the items entered programmatically. Here's the question. I'd like more information, such as when it was added and when it will expire, also, what pages and controls are in the cache and when they will expire. How do I do this? .......... If nCacheCount > 0 Then Dim CacheEnum As IDictionaryEnumerator = Cache.GetEnumerator() While CacheEnum.MoveNext() drCache = dtCache.NewRow() drCache("name") = CacheEnum.Key drCache("value") = CacheEnum.Current.Value.ToString() drCache("na") = "" dtCache.Rows.Add(drCache) End While ............... thanks, -phil |
#4
| |||
| |||
|
|
Thanks Alvin. Ok then, how about a tool of some sort for the IIS Administrator that would expose this cache information locally to the console? Secondly, what is the appropriate counter to moitor through the performance counter that would reveal cache usage? Regards, -phil "Alvin Bruney [MVP - ASP.NET]" wrote: that info isn't exposed to the outside world because of the dictionary implementation. what you see is exactly what you get. -- Regards, Alvin Bruney - ASP.NET MVP [Shameless Author Plug] The Microsoft Office Web Components Black Book with .NET Now available @ www.lulu.com/owc "vbphil" <vbphil (AT) online (DOT) nospam> wrote in message news 76C01F6-BDBF-45E5-BECB-A5BC34AC28B7 (AT) microsoft (DOT) com...I'm caching aspx pages and ascx controls as well as programmatically within aspx code for my asp.net web application. I'd like to have a special admin aspx page that will display the contents of the cache. I'm using the IDictionaryEnumerator, see code snippet below, but this just gets me the value or data type and the key of the items entered programmatically. Here's the question. I'd like more information, such as when it was added and when it will expire, also, what pages and controls are in the cache and when they will expire. How do I do this? .......... If nCacheCount > 0 Then Dim CacheEnum As IDictionaryEnumerator = Cache.GetEnumerator() While CacheEnum.MoveNext() drCache = dtCache.NewRow() drCache("name") = CacheEnum.Key drCache("value") = CacheEnum.Current.Value.ToString() drCache("na") = "" dtCache.Rows.Add(drCache) End While ............... thanks, -phil |
#5
| |||
| |||
|
|
Well, if a tool can do it then user code can do it. That isn't the case. In any case, a tool runs outside of the executing process which definitely does not have access to the cache instance. I'm not aware of any counter that monitors cache usage, counters can measure memory usage which is directly dependent on cache usage. What exactly are you after? Are you having memory issues? -- Regards, Alvin Bruney - ASP.NET MVP [Shameless Author Plug] The Microsoft Office Web Components Black Book with .NET Now available @ www.lulu.com/owc "vbphil" <vbphil (AT) online (DOT) nospam> wrote in message news:FEFFA7AF-9397-4B28-AAA2-E4603A85B08E (AT) microsoft (DOT) com... Thanks Alvin. Ok then, how about a tool of some sort for the IIS Administrator that would expose this cache information locally to the console? Secondly, what is the appropriate counter to moitor through the performance counter that would reveal cache usage? Regards, -phil "Alvin Bruney [MVP - ASP.NET]" wrote: that info isn't exposed to the outside world because of the dictionary implementation. what you see is exactly what you get. -- Regards, Alvin Bruney - ASP.NET MVP [Shameless Author Plug] The Microsoft Office Web Components Black Book with .NET Now available @ www.lulu.com/owc "vbphil" <vbphil (AT) online (DOT) nospam> wrote in message news 76C01F6-BDBF-45E5-BECB-A5BC34AC28B7 (AT) microsoft (DOT) com...I'm caching aspx pages and ascx controls as well as programmatically within aspx code for my asp.net web application. I'd like to have a special admin aspx page that will display the contents of the cache. I'm using the IDictionaryEnumerator, see code snippet below, but this just gets me the value or data type and the key of the items entered programmatically. Here's the question. I'd like more information, such as when it was added and when it will expire, also, what pages and controls are in the cache and when they will expire. How do I do this? .......... If nCacheCount > 0 Then Dim CacheEnum As IDictionaryEnumerator = Cache.GetEnumerator() While CacheEnum.MoveNext() drCache = dtCache.NewRow() drCache("name") = CacheEnum.Key drCache("value") = CacheEnum.Current.Value.ToString() drCache("na") = "" dtCache.Rows.Add(drCache) End While ............... thanks, -phil |
#6
| |||
| |||
|
![]() |
| Thread Tools | Search this Thread |
| Display Modes | |
| |