OL Learn

Workflow Actively Running Processes

I know this is a frequently raised issue, but I need to raise it again.

How do I tell if, and what, Processes are CURRENTLY running?

The Workflow Console and logs only show results for jobs (Workflow Processes) that have been completed.

Is there an API call, perhaps, or some other method to know: what is PlanetPress Workflow doing RIGHT NOW?

My client is a large government print shop and we need to frequently add or modify Workflow Processes. Without knowing if any jobs are currently running, “Send Configuration” is always risky. Maybe the services will restart quickly, or maybe everything, including some other processes that run frequently through the day, will shut down and then the server is stuck running that one big job through to completion and the other processes, and the changes just made, are unavailable for hours.

I need to be able to, at a glance, know if PlanetPress is running any processes, and ideally, what plugin/task it’s currently on within that process.

To my knowledge there is no API that provides the functionality you request BUT, you could achieve this using the Workflow Repository.

The idea is to define a Group for each Workflow process. In each group you define 1 key which will contain a single value 0 or 1.

Each Keyset will refer to each step of the process (or important step like a Execute Datamapping but not a Set Jobs Infos and Variables one, I’ll leave that to you).

At first, for each Keyset would be set to 0, indicating that the corresponding step hasn’t been executed yet. Once it has been executed in a process, you would set it to 1 and so on until the end where you reset all of them to 0.

Now based on that, you can define a Workflow process that queries the Repositoryat specified interval and update a dashboard.

I have implemented something very similar already, using the Data Repository. I’ve even added scripts to both the Data Mappers and Templates we implement to add current record count to the Repository so we can not only know what step a process is on, we know the percentage complete of each step of each job. This all gets serialized out to a JSON file, and is served through AJAX to a web-based Job Status Page.

The issue is, we haven’t retrofitted all of the dozens of processes and hundreds of Connect Resources to use this dashboard (I think I invented the Dashboard concept back in the day when I was with Pitney Bowes!!)

And, not everyone has the time or skill set to build HTML dashboards, so I would like to make this a Feature Request: please add some mechanism within the Workflow Console or the Workflow Configuration screen that displays a list of currently running processes.

I have open an improvement request on your behalf. For your reference: TS-5639.