LinkActivity Check Page

Process Director runs as a virtual directory in IIS and processes all time-related events only when activity is present on the system (e.g. Users are actively working on the system). Process Director doesn't have a constantly running timer service; Timers can only be called when IIS is active and it is processing web page requests. So, while Process Director is a near real-time system on an active installation, it is not a real-time system. Time-based events like condition evaluations, due date checks, activity notification schedules, and so forth are only prompted when the timer checks run. On an active system, of course, user activity prompts the time checks to run more frequently. Conversely, on an inactive system, like a development or staging system, the lack of user activity means that timer checks will run far less frequently.

Additionally, if there are no active users, IIS goes inactive and shuts down after 20 minutes of inactivity, by default. We want to avoid that during business hours, but still leave some time for IIS to restart on its own during a period of inactivity. So, we have provided an activity check page in the installation folder, named activity_check.aspx.

The activity check page does a couple things. First, it keeps IIS active so it doesn't shut down and need to restart during the business day. Second, it prompts the timer checks to invoke all of the time based events like due date checks, etc., so, even on an inactive system, time checks will still occur on a regular basis when the activity check runs, even if no users are on the system.

For on-premise installations, BP Logix recommends setting the activity check page to run every 15 minutes for a duration of 15 hours to cover the entire business day. Setting the activity check timer to 15-minute intervals will prevent IIS from shutting down every 20 minutes if the system has no active users, while ending the checks after 15 hours allows IIS to shut down the Application Pool at night, when the system isn't active. This configuration also ensures that timer checks will run within fifteen minutes of the expected time.

Important BP Logix implements the appropriate activity check scheduling for installations that reside in the BP Logix Cloud.

While the activity check page is running, it tells Process Director that timer process should NOT occur under the context of a user, but only occur in the context of the running activity_check.aspx page. If timer processing occurs under the context of a user, they may see their session hang while the activity check processing is occurring, but setting the timer context to the activity check page will avoid this. Time checking will reset to user context when the activity check is complete.

To run the activity check page on a scheduled basis, you can set the following command in the Windows Scheduler utility to be run according to the highlighted schedule above:

PATH\bputil.exe" SU "http://localhost/activity_check.aspx"

In this example, PATH is the installation directory for Process Director (e.g. c:\Program Files\BP Logix\Process Director\).

There are a number of URL parameters that you can apply to the URL for the activity check page above that will enable the activity check to check specific processes. Only one of these URL parameters can be used at any time.

  • WFID: A specific Workflow definition.
  • WFINSTID: A specific Workflow instance.
  • PRID: A specific Process Timeline definition.
  • PRINSTID: A specific Process Timeline instance.

For instance, you can do an activity check on a Workflow definition by using the command

PATH\bputil.exe" SU "http://localhost/activity_check.aspx?WFID=XXXXXX"

The activity check page can't be run from a remote host. It can only be executed from the local server where Process Director is installed, or run remotely when logged in as an administrator. Assuming that the remote host is a secure server, however, you can add the remote server to the list of "local IPs" in the installation settings to cause Process Director to treat the remote host as a local host.

When the activity check page runs, Process Director will determine which timer processing functions need to occur. (There are a few things like GOALS that will be evaluated EVERY time the activity check runs because they are low-impact.) You can control the timer functions by setting custom variables in the vars.cs customization file. These timer functions are NOT controlled by the frequency that the activity_check.aspx page is scheduled.

There are several Custom Variables that control the amount of time to wait between different types of timer processing. These Custom Variables, examples of their configuration, and other details, are provided in the Activity Checking Custom Variables topic of the Developers Guide.

There are ways for force the timer processing to occur without being governed by the Custom Variables. Instead, you can pass special URL parameters on the activity_check.aspx URL query string. For example, you can pass a Workflow definition ID (WFID) on the URL, which tells Process Director to process all timers for all running Workflow instances under that definition. This should be used with care to prevent excessive resource utilization if used too often. The following URL Parameters are available to run timers on specific objects:

  • STINSTID
  • ACTINSTID
  • WFINSTID
  • PRINSTID
  • WFID
  • PRID
  • MLID

Timers can also be manually forced from the Troubleshooting page of the IT Admin area, by clicking the Run Timers action link.

Important Process Director v4.52 and higher implements advanced timer checking to ensure that new instances of a running timer can't be created until the current instance of the running timer has completed.