Crons

The Cron section is available under Administration > Crons.

Cron is a system tool used to automate recurring tasks, such as:

  • Data backups
  • Plugin execution
  • Data downloads
  • Other scheduled operations

Cron allows users to automatically run scripts, commands, or plugins at specified intervals without manual intervention.

How Cron Works

Cron operates using "cron jobs" or "cron tasks." Users define a schedule (cron table) that specifies when and how often a task should run.

Tasks can be scheduled to run at various intervals, such as:

  • Daily
  • Weekly
  • Monthly
  • Custom intervals based on user needs

Only an Application Administrator (role: $Administrator) can define and manage dynamic cron tables.

Cron Actions

1. Manual Stop

If a cron job needs to be stopped before completion:

  • Select the cron job
  • Click Stop

2. Manual Start

To run a cron job outside of its scheduled time:

  • Select the cron job
  • Click Start

3. Change Status

To change the status of a cron job:

  • Select the cron job
  • Click Status
  • If the cron job is inactive, this will activate it and vice versa.

4. Delete

To delete a cron job:

  • Select the cron job
  • Click Delete

⚠️ Warning: Deleting a cron job is not recommended. Instead, it is better to change its status to inactive.

5. Restart

Restarting a cron job may be necessary for several reasons:

  • Configuration Changes: If modifications are made to the cron table (e.g., adding, editing, or removing cron jobs), a restart ensures the updates take effect.
  • Execution Issues: If cron jobs fail or encounter errors, restarting may resolve the problem.
  • System Updates: If the operating system is updated, cron services may need a restart.
  • Error Resolution: If the cron service becomes unstable, a restart can restore normal operation.

To restart a cron job:

  • Click More > Restart

Available Cron Jobs

Below is a list of common cron jobs and their functions:

AdSyncCron.js

  • Synchronizes users from Active Directory.
  • Recommended to run outside business hours to avoid disruptions.
  • More details on user synchronization here.

CertificatesValidationCron.js

  • Validates security certificates.

CleanPerfLogsCron.js

  • Clears performance logs.

CompetenceGeneratorCron.js

  • Assigns user roles based on competencies.
  • More details here.

Cron.js

  • Runs all scheduled tasks and events.
  • Recommended schedule: Every 5 minutes, starting at second 1.

CustomViewsMeasure.js

  • Tracks custom view metrics.

DeleteLogs.js

  • Deletes old logs from the system.

DmsFileIndexingCron.js

  • Indexes document management system (DMS) files.

ElasticsearchIndicesCleanupCron.js

  • Cleans up old Elasticsearch indices.

EwsCreateProcessesFromMailCron.js

  • Processes emails and creates tasks from inbox messages.
  • More details here.

iDokladSynchronizationCron.js

  • Syncs data with iDoklad.

MailCustomViewsCron.js

  • Sends custom reports to users via email.
  • More details here.

MailReportsCron.js

  • Sends system-generated reports via email.

MailTasksCron.js

  • Sends email notifications related to tasks.
  • Affected by settings:
    • sails.config.newTaskNotificationEnabledByDefault
    • sails.config.promptlyDelay
  • Can be modified to send "Failed" emails by setting the status to F.

MailUsageStatisticsCron.js

  • Sends monthly usage statistics via email.

MigrateIJStoTJS.js

  • Migrates data from IJStoTJS.

PasswordExpirationNotificationCron.js

  • Sends password expiration reminders.

PlanCron.js

  • Executes predefined plans from the Planning module.
  • No scheduling required.

RunProcess.js

  • Executes scheduled business processes.

SyncProcessRightsCron.js

  • Synchronizes user permissions for processes.

TemplateProcessShredding.js

  • Manages the shredding of expired processes.
  • More details here.

UsageStatisticsCron.js

  • Collects and sends system usage statistics.

XMLProcessImport.js

  • Reads XML files (often containing PDF attachments) and imports them into process variables.
  • Multiple instances of this cron job can run simultaneously to handle different processes.

Anna Gernát Updated by Anna Gernát

Logs

Access Token Settings & Session Expiration

Contact

Syca (opens in a new tab)

Powered by HelpDocs (opens in a new tab)