Performance issues with high memory consumption and CPU load for medium-to-large stacks #9477
-
Description of topicI am dealing with RAM/CPU (memory/load) issues with my Node.JS / Typescript Automation API stack when it grows beyond a certain size, and this discussion is for those having similar issues with memory & CPU for any Pulumi user (not just those with my stack). I am not creating an issue, because I don't have a ready-made reproduction, nor do I have code samples. Instead, I would like to begin to collate various issues/PRs that I've been reading that all touch on this issue. Observed outputAccording to PM2, as soon as my Pulumi "program" is finished running (for a preview), there is a consumption of greater than 100% (~135%-145%) CPU and with an available memory of 24GB, it quickly goes up to 14GB and above. I used node options to increase the max-old-space-size to 75% of my machine's total RAM (32 GB). PM2 logged:
When pausing the script shortly after a hang, the
Modified behaviorI have tried selectively targeting single URNs, but even that still seems to trigger the issue. EnvironmentI was using the latest Pulumi version, but I just switched the latest alpha to see if that would help. Here are my versions now:
Hunches
Related issues & pull requestsNewest first:
* Not strictly specific to performance issues, but collating here for awareness. Searches
|
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 7 replies
-
I think I may have found my issue. Circular serialization of objects passed into a ComponentResource, despite not being included in the output or args, could be causing infinite serialization. |
Beta Was this translation helpful? Give feedback.
-
Team, in the latest releases of pulumi something really wrong 3.34+, getting Thanks |
Beta Was this translation helpful? Give feedback.
I think I may have found my issue.
Circular serialization of objects passed into a ComponentResource, despite not being included in the output or args, could be causing infinite serialization.