Crons

Crons are scheduled jobs that TAS runs automatically at a set time: they send e-mail notifications, start scheduled processes, publish news, delete old logs, synchronise users and so on. On the Crons page you monitor their status, browse the run history and edit their settings. The page is available to administrators; open it from the Administration menu using the Crons tile in the Application management and configuration group.

The page has three tabs: Cron monitor, History and Crons.

Cron monitor

A live overview of all crons with their latest runs and status.

No.ElementPurpose
1Cron monitorTab with the status overview.
2HistoryTab with a list of individual runs.
3CronsTab with the list and settings of crons.
4CloseReturns you to the Administration menu.
5NameSearch for a cron by name.
6StatusShows only crons in the selected state: All, Error, Warning, OK.
7Show inactiveAdds disabled crons to the overview as well.
8Statistics periodThe period over which the success rate and average duration are calculated: 1 hour, 8 hours, 1 day (default), 3 days, 1 week or All.
9Auto refreshThe overview refreshes itself every 10 seconds. Enabled by default.
10RefreshImmediately loads the current status.
11Indicator helpExplains when a cron is shown in red and when in orange.
12Problem summaryA list of crons that have a problem, with the reason. Click a cron name to jump to its card. When everything is fine, a green confirmation is shown here.
13Traffic lightColour of the cron status: green OK, orange warning, red error.
14FavouritesUse the star to mark a cron as a favourite. The mark applies only to you.

Cron card

FieldMeaning
Name and typeThe cron name and its origin: Platform (part of TAS) or Plugin. The description is shown below the name.
Cron timingWhen the cron runs, in the format seconds, minutes, hours, days, months, days of week.
Next runWhen the cron will run next.
Last run, FinishedWhen the last run started and ended.
Last durationHow long the last run took.
Last resultFinished, Error or Running.
Last successWhen the cron last completed without an error.
HeartbeatWhen a running cron last reported in.
Success rateThe share of successful runs in the selected period, with the number of runs in brackets.
Average durationThe average run length in the selected period.
Consecutive failuresHow many times in a row the cron ended with an error.
LabelsReasons for the warning, for example failed 8 times in a row or no successful run yet.
ErrorClick to display the text of the last error.

A running cron also shows Running since, Running and Instance.

A cron is shown in red when it has failed repeatedly in a row (the default threshold is 5 failures; it is set in Configuration with the application.crons.consecutiveFailureThreshold item, which also determines when a failure e-mail is sent to the addresses in application.crons.sendErrorMailAddresses). It is shown in orange when the last run failed, the cron has never run successfully, it has not run successfully for longer than three of its intervals, it did not start at its scheduled time, or it is running significantly longer than usual.

History

A list of individual runs of all crons, newest first.

No.ElementPurpose
1RefreshReloads the list.
2Run IDIdentifier of the run.
3CronName of the cron.
4StatusFinished, Error, Running or Killed.
5Actual startWhen the run started.
6Actual endWhen the run ended.
7TriggeredScheduled (according to the timing) or Manually (started by an administrator).
8Trace IDIdentifier you can use to find the run's records in Logs.
9Row actionsDetail opens the run page.

Run detail

No.ElementPurpose
1Cron runRun details: Run ID, Cron, Cron type, Description, Status, Triggered, Start, End, Last duration, Trace ID and, for a failed run, Last error.
2LogsLog records of this run with the columns Date, Message, Category, Level and Trace ID. You can narrow the list with the Time range button.
3CloseCloses the run detail.

Crons

No.ElementPurpose
1Add cronOpens the window for adding a cron.
2RefreshReloads the list.
3Terminate cronsRestarts all services that execute crons. See the warning below.
4NameName of the cron.
5Technical nameIdentifier of the job in the code. One technical name can have several crons with different names and parameters.
6StatusActive or Inactive. An inactive cron does not run.
7Cron timingWhen the cron runs.
8DescriptionWhat the cron does.
9Run manuallyAfter you confirm Do you really want to run the selected cron?, the cron runs once immediately, outside its schedule.
10Row actionsMenu with Edit, Activate/Deactivate and Delete.
ActionWhat happens
EditOpens the cron detail.
Activate / DeactivateTurns regular execution on or off.
DeleteAfter you confirm Do you really want to delete the selected cron?, the cron is removed and its scheduling stops.
Terminate crons
The button asks Do you really want to terminate all crons? and then stops all services that execute crons. Running jobs are interrupted and the server environment restarts the services. Use it only when a cron is stuck and not responding. Use manual runs with care as well: for example, the e-mail sending cron sends notifications to real users.

Most important crons

Technical nameWhat it does
MailTasksCronSends e-mail notifications about tasks (every 5 minutes by default).
MailReportsCronSends overviews of tasks and escalated tasks.
PlanCronStarts scheduled processes from the Planning section (every minute).
PostponedTaskCronActivates postponed tasks and scheduled events.
PublishPostsCronPublishes scheduled news and ends news after their end date (at midnight).
DeleteLogsDeletes old logs according to the retention periods in its parameters.
CleanupCronDeletes old data from the database, for example performance logs, cron run history and the e-mail queue.
ArchivationCronArchives cases according to template settings.
TemplateProcessShreddingPermanently shreds cases after the template's shredding period has expired.
AdSyncCronSynchronises users and groups from Active Directory (LDAP).
CompetenceGeneratorCronCreates and removes roles assigned based on competences.
GenerateThumbnailsCron, DmsFileIndexingCronCreate document thumbnails and index documents for search.
UsageStatisticsCron, MailUsageStatisticsCronCollect usage statistics and send them by e-mail.
PasswordExpirationNotificationCronNotifies users of upcoming password expiration.
B2bAndSecretStoreValidationCronMonitors expiring secret keys, API tokens and OAuth clients.
MsGraphCreateProcessesFromMailCron, XMLProcessImportCronCreate cases from e-mails in Microsoft 365 or from XML files.

Which crons are active and how often they run depends on the settings of your installation.

Add cron

FieldPurpose
Select cronRequired. The job you want to schedule. The list shows the technical name and origin (PLATFORM or PLUGIN). After you select it, the other fields are prefilled with the job's default values.
NameRequired and unique. Defaults to the job name.
Cron timingSix fields: Seconds, Minutes, Hours, Days, Months, Weeks. A readable description is shown above the fields, for example At 12:00:00 AM. The value * means every.
StatusActive switch.
DescriptionOptional description.
ParametersJob settings, if it has any. The form is validated before creation.
CreateCreates and schedules the cron.
CloseCloses the window. If you have filled anything in, the application asks Save changes?.

You can add the same job several times under different names, for example with different timing or parameters.

Cron detail

No.ElementPurpose
1CloseReturns you to the list of crons.
2LogsOpens the log records of this cron.
3Factory settingsAfter you confirm Do you really want to reset the cron to factory settings?, it resets the timing, description, parameters and status to the job's default values. The name is kept.
4Import / ExportWindow with the cron definition in JSON format. Copy the definition to another environment, or paste a definition of the same job here.
5SaveSaves the changes.
6Save and closeSaves the changes and returns you to the list.
7Technical nameThe job the cron runs. Read-only.
8NameRequired cron name.
9DescriptionOptional description.
10Cron typePLATFORM or PLUGIN. Read-only.
11Cron timingSix timing fields with a readable description.
12StatusActive switch. A cron with invalid timing cannot be activated.
13ParametersJob settings. For each parameter you see help text, the technical name and the default value. Parameters of plugin crons are read-only.

After you save a change to the timing, parameters or status, the cron is rescheduled immediately. Crons for importing e-mails from Microsoft 365 also have a Detect folders button, which loads the mailbox folders and helps you select the input and output folder.

Example: keeping logs longer
Open the cron with the technical name DeleteLogs, increase Error Warn in Parameters to, for example, 60, and save. Errors and warnings in Logs will then be kept for 60 days.

Related: Logs, Configuration, Planning, News management.

Parallel cron - PostponedTaskCron

CleanupCron

Syca (opens in a new tab)

Powered by HelpDocs (opens in a new tab)