Docker Server Not Running due to Workflows

Hello everyone,
I hope to find you well.

Im making this topic because this week our docker image of corteza wouldnt run even after reseting and backing up a previous snapshot. After testing, we disabled all workflows and the server started just fine so we tried to find out if there was a workflow causing problems and we landed on 3 where one had trigger every 2 minutes and the other two were having stale data issues and piling up a bunch of sessions because of it. We think that the issue is because the server is taking too long to start and its creating a trigger which cant run because it wont find the models called on the workflow so it throws an error and enters into panic.

Is there any way to avoid this? Maybe some update to the code to make it so triggers can only start after everything is loaded correctly? I also ended up founding a constant on the code defining the max events/triggers to 16. Is this for the workflow triggers? If so then we probably have more than that. Im mentioning it in case this could also be an issue.

Thanks for any help!

Best Regards,
João Figueiredo

Created an issue for this, thanks for reporting.

Would it be possible to disable triggers in DB, then start the server and then enable them?

Yes, thats what we did but after some time we would start having some problems when trying to save records or workflows.

We assume that there is something causing a loop of some kind and making it so other processes cant run.

Currently we have all triggers disabled and some workflows turned off and the issue wasnt happened again for now.