I was wondering if there's a way to suspend new execution of workflows. But keep the existing one still running.
I'm asking because when I want to plan an upgrade and a huge workflow starts (our main one takes about 2 hours to complete), so if want to plan a maintenance/upgrade at 2PM, so I always have to ask users to stop launching workflows like 2 hours in advanced. But if there could be a wait to keep VRO Up, but prevent any new workflows from running that would be great, so I don't brake any existing workflow.
Thanks!
We've created a "Maintenance Mode" framework where we use configuration elements to control whether this mode is enabled or disabled and also additional configuration elements for some individual activities. For items we want to put into a holding pattern we drop a "Check Maintenance Mode" workflow as the first item and it just sleeps if the maintenance mode check is true. We have the sleep time as a config element as well. This way we can set maintenance mode on/off globally or conditionally for individual workflows. Works really well for us.
How do your users launch workflows? The client?
If your users use vRO Java client to launch/schedule workflows - there is no direct option to prevent it.
If your users use REST API calls to launch/schedule workflows, then probably you can try to put vRO behind a proxy/load balancer, and implement some logic to reject certain REST API calls during maintenance/upgrade periods.
Ah yeah... I forgot about that, yeah we normally launch the workflows via the REST API, and forgot about the load balancer.
I'll see what we could do with this!
We've created a "Maintenance Mode" framework where we use configuration elements to control whether this mode is enabled or disabled and also additional configuration elements for some individual activities. For items we want to put into a holding pattern we drop a "Check Maintenance Mode" workflow as the first item and it just sleeps if the maintenance mode check is true. We have the sleep time as a config element as well. This way we can set maintenance mode on/off globally or conditionally for individual workflows. Works really well for us.
That is a very good idea!!! I was already using something similar but for the VRO environnement value, if its my dev, skip some steps. If its prod do some extra steps.
But I haven't thought about doing that with a "maintenance mode". Well I won't have any choice to steal your idea!
I don't want to be dependent on the guys that manage the load balancer, and that way I'll be able to do whatever I want when I want.