dave
LFU/LRU InProc .NET Weighted Entry Cache?
Looking for recommendations for a local cache bounded by size (not count) like IMemoryCache is, but implementing a LFU (or LRU I guess) eviction policy.
Seen DotNext and BitFaster but they are bounded by N entries without any weight (such as
string.Length
for a size for example).
For a high-enough-to-worry traffic production app (layer in front of redis) so I don't want to go writing eviction policies for e.g. CacheManager cause I'll get it wrong.1 replies
❔ OOM well below GCHeapLimit (Could not do a full GC) since .NET7
The GCHeapLimitPercent is set to 75%, which equates to about 3gb in the container - working well in netcore3.1 for a long time.
We've updated to .NET7 and getting some OOM, but our collected heap dump is only showing around 300mb allocated on the GC heaps (looking in dotnet dump analyze dumpheap -stat / eeheaps / analyzeoom).
We catch these dumps with a ASP middleware catching OOM exceptions which calls into Environment.FailFast to let createdump capture a dump (we're using COMPlus_DbgEnableMiniDump etc).
Has anything changed in GC since .NET7 that could affect this? I assume I'm going to have to start looking into unmanaged memory but I can't get the dumps open in dotMemory or VS memory debugger for some reason.
18 replies