-
Notifications
You must be signed in to change notification settings - Fork 104
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[Bug] Memory leak on the temporal worker side(OperatorSubscriber Class Objects are taking much of the memory) #1541
Comments
What happens if you continue feeding workflows to the worker? Does memory continue to go up, or does it stay stable around some value, e.g. ~300MB? The Worker caches Workflows in an LRU; a Workflow stays in the cache until it gets evicted either 1) to make room for another workflow that’s coming in, or 2) because processing of a Workflow Task failed. Completion of a Workflow doesn’t result in eviction. That means that, assuming there’s no Workflow Task failures, the sticky cache size should quickly grow up to its maximum value, and then stay at that number for very long period of time (i.e. until the pod gets shutdown). |
Hi @mjameswh , |
As I said before, we do not expect a Worker's memory usage to come down once a Workflow has completed. Completed Workflows may still be queried, so caching them may still be beneficial. What we'd expect is for memory usage to grow until the cache size reaches its maximum capacity (
Your screenshot indicates 43'890 instances of
|
@jainshivsagar Are you still observing issues, or may we close this ticket? |
What are you really trying to do?
We are using the TypeScript SDK v1.9.0 for our temporal worker.
We are doing the load testing in the local System. At the start of the worker the Memory(or Heap) utilization was <120MB, post the load testing, the Memory(or Heap) increased to ~300MB. After 5-10 minutes of load testing the memory utilization didn't come down.
Please refer to the below screenshots of Chrome DevTool(Memory Profiler):-
Memory Utilization after starting the worker:-
Memory Utilization after load testing:-
Comparison of first two Heap snapshots:-
Environment/Versions
Worker Configurations:-
The text was updated successfully, but these errors were encountered: