Entity Requeuing and .net 10 #1121
Unanswered
treyhendon
asked this question in
Q&A
Replies: 1 comment 7 replies
-
|
hey @treyhendon, thanks for starting this discussion and sorry for asking - but just to get it right as I am no native speaker: you are using v10.5.0?
we are using the operator with .NET 10 in production, staging and development - with no heavy retrying but with queued retries. actually we don't see the meory increasing that much. and just out of curiosity: where did you read that .NET 10 isn't fully supported? from my perspective it should be 😄 if there is still a gap somewhere we should address that. thanks, |
Beta Was this translation helpful? Give feedback.
7 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment

Uh oh!
There was an error while loading. Please reload this page.
-
Hi all,
I wanted to start a discussion (not Issue yet) because I found a problem, but it's possibly not a dotnet-operator-skd issue - it might be a ZiggyCreatures.Caching or .net 10 issue. Also, I understand that .net 10 is not listed as fully supported and I'm running a little ahead.
TLDR; Using dotnet-operator-sdk 9.x or 10.x and updating to .net 10 will cause a memory leak when entity requeuing is used.
Using gcdump I did a lot of digging and found that cache objects (including JsonSerializerOptions in the tree of cache objects) were the biggest offenders.

For this image, memory started around 100MiB for the baseline gcdump and was above 600MiB for the comparison (after 16 hours of running).
I am calling out the Controller Requeue because it is critical for my operator and can understand that it's probably a less commonly used feature. I performed a round of testing on .net 10 and removed all requeue logic from my code. Console logging showed the initial entity reads from k8s were added to the memory cache, then the app resources remained stable as it ran for hours. I am assuming this was because there were no new writes to the cache like the requeue feature does.
I should also point out that I tested both forms of requeuing - the original
EntityRequeue<T>and the new ReconciliationResult requeueAfter option. There was no difference in the outcome.Ultimately, I found that I could use the latest version of dotnet-operator-sdk (10.5.0) and simply switch between .net 8 and .net 10 in my container to invoke (or resolve) the memory leak.

Does anyone else use the requeuing feature heavily? Has anyone else tried upgrading to .net 10 yet?
Beta Was this translation helpful? Give feedback.
All reactions