Scheduled Task

ScheduledTask general information

A ScheduledTask is more or less the same as a Business Rule. However, instead of being triggered by a save action, it is triggered by a timer.
For more general information please visit: https://webhelp.planoncloud.com/en/Platform%20apps/c_pp_scheduled_task.html
Where a Business Rule has a reference to a BusinessObject (BO) (the one that is being saved), a ScheduledTask is completely stand-alone. The configuration itself is responsible for finding and loading the BusinessObjects to operate on.
Typical use cases are periodic checks, clean-up actions, recalculations and sending notifications at a specific moment in time.

Behavior of a ScheduledTask

The following statements are true:

  • There is no triggering BO. Therefore there is no “Old” and “New” value and functions like Field changed are not applicable.
  • The BusinessObjects to process must be fetched in the flow, for example with Find by unique field, Find by lookup or Goto element.
  • Changes are not saved automatically. An explicit save function must be added on every BO that is changed.
  • There is no user interaction. Notification functions like Show warning, Show error and Show confirmation have no visible effect; use Add to LogViewer to report the result.

Configuration

The ScheduledTask solution type is only available from experience level 2 (Advanced).

  • Create a new configuration in the free module. Provide a Code and a Name / Description and save. See Planon configuration.
  • Open the editor via the link button and click on advanced in the left menu.
  • On the Start of flow node set the Solution type to ScheduledTask.
  • Build the logic: fetch the BusinessObjects to process, apply the changes and add the save functions.
  • Save the configuration.

Registering:

  • Go to the scheduled tasks configuration in Planon.
  • Click Task user extension
  • Click add
  • Select the Logic Flow Builder scheduled task class planonsoftware.apps.configurablebusinessrule.ConfigurableScheduledTask from the Class Name reference.
  • Provide the configuration code in the settings.
  • Set the schedule (start date/time and interval) as per business needs.
  • Save the changes and make sure the scheduled task is active.

Licensing

Each ScheduledTask registration with a unique configuration counts as 1 license. The license usage is visible on the License usage tab of the in-app manual.