Is there any time/resource limitation for a process to run in a machine?

Hi Team,

I just deployed a Shopify Remix app which is supposed to run once a day a process that can take up to 2h to complete. I started the process today and it finished with this error here:
[warn] Virtual machine exited abruptly

Is there any time/resource limitation for a process to run in a machine?

I don’t believe there are any time limitations, but there are definitely resource limitations. What kind of jobs are you doing that’s taking 2 hours? It’s most likely an OOM error, check your grafana charts for anything suspicious.

Hi, I literally iterate over the Catalog and update price of some variants. There is definitely space to improve the process itself. At this moment, it is running for like 20 min and it crashes. I will implement the changes to the process and see if it is able to complete. I am still doubting if the premise of how this is implemented is right. Basically, I expose an endpoint via remix that once pinged it will execute this function. I am really wondering if there is not a better way to do this. Do you have any thoughts about the topic?

Regards,
Rodrigo

Did you look at your memory usage in your dashboard? Maybe you have a memory leak.

Echo’ing on what @khuezy said, I would check the Grafana dashboard to see if there is any memory leak, or excessive CPU usage (although CPU usage shouldn’t crash it, just it’ll take forever).

There aren’t any time limits on machines running though, in fact it’s fine to run them 24/7.

I am actually employing an extremely similar use case on one of my processes, running a job every few hours to fetch all products in a Shopify catalog and update information on the product accordingly. How I’m doing it though is to have a cron process that calls functions on a schedule, one of the functions called is the “product updater” that goes through all the products and updates them accordingly. Whether or not your solution or mine is the better is up to each use case, however yours in principle should work. Do you perhaps have any exceptions that would crash the program, or other logs indicating what happened?

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.