- About XNAT
- News & Events
- XNAT Marketplace
- Contact Us
New in XNAT 1.8.5 is functionality that allows system administrators to schedule timed execution of automated actions using the XNAT Event Service
As a user with administrator privileges, browse to the Administrator -> Event Service page and select the Add New Event Subscription button.
In the Create Event Subscription dialog, use the Select Event dropdown and select Scheduled Event – Cron option.
This will reveal additional subscription options specific to Scheduled Events.
Cron Trigger - A Cron Expression that defines when this event will trigger. (e.g. 0 50 12 * * *)
Cron Description - A human readable description of the cron trigger. (e.g. 12:50pm everyday)
Once you've filled out the cron trigger and description, enable and save the event subscription. Your new Scheduled Event will now fire at the interval you specified in the cron trigger.
In the example below, the debug-session command will run on all sessions in all projects at 12:50pm everyday.
In an event subscription that reacts to an event triggered by a user, the resulting action can be associated with the user who triggered the event using the "Perform Action As" setting. In a scheduled event, there is no external user trigger, so any action triggered by a scheduled event is associated with the user who created the event subscription.
If the subscription's action is a container service command, the command must have an external input that is supported by Scheduled Events. Inputs that are currently supported are Project, Project Asset, Subject, Subject Assessor, Session, and Assessor. Commands that don't have a supported external input will not be processed by the subscription.
Scheduled Events are not currently supported on the project level (Project Report > Actions Box > Event Service). This means that project owners are not currently able to schedule events for their projects. Events can still be scheduled for individual projects, but a system administer will need to create the subscription from the Administer > Event Service page.
Wildcards(*), ranges(-), step values(/), and lists(,) are not supported in the Subscription's Cron Trigger minutes or seconds fields.