Does the Debug Memory Usage step in Pipedream Utils report the Workflow's memory usage or the Step's memory usage?

This topic was automatically generated from Slack. You can find the original thread here.

Since each step in a Pipedream workflow is run in its own process (according to the “Out of Memory” section of the Troubleshooting documentation), does the Debug Memory Usage step (code is here), from Pipedream Utils, report the Workflow’s memory usage or the Step’s memory usage?

The Debug Memory Usage step from Pipedream Utils reports the memory usage of the individual step in which it runs, not the memory usage of the entire workflow. ### Explanation - As noted in the Out of Memory section of the Troubleshooting documentation, each step in a Pipedream workflow runs in its own process. This means memory is isolated per step. - The Debug Memory Usage action measures and reports the memory usage within the context of the current step’s process. - It does not aggregate or report the total memory usage across all steps in the workflow. If you want to monitor memory usage for a specific operation, add the Debug Memory Usage action immediately before or after that step. But remember, it only reflects the memory used by that particular step’s process. If you have more questions or need help troubleshooting memory issues, please see Pipedream.

Since the Debug Memory Usage pre-built step only reports its own memory usage, is there a way to see a Workflow’s memory usage, to help troubleshoot Out-Of-Memory (OOM) errors?

Is it possible to import the Debug Memory Usage step from Pipedream Utils into a custom Node.js step and “run” it there?