A Trigger is a stored procedure that is activated automatically when a specified event occurs. Typically, there are three event types that activate Triggers: delete, insert or update (see below). Triggers can be used to perform many tasks, such as auditing catalogs, records and categories. Cumulus Triggers complement the capabilities of the Cumulus Scheduler. The Scheduler might cause an event that activates a Cumulus Trigger.
Triggers can be set for catalogs, records and categories.
Once set, a Cumulus Trigger can be temporarily disabled (deactivated) and enabled (activated) again. This can be very useful when testing a configuration, or when searching for errors.
Cumulus Triggers are defined by:
• Events — The event that will activate the Trigger.
• Trigger Actions — The function that will be performed when the Trigger is activated.
Trigger events for a catalog can either affect the catalog itself (updated Catalog Settings), or all records or categories of the catalog.
Event types that can be chosen for all records or all categories of a catalog are:
• Item Deleted — A record or category of the catalog was deleted.
• Item Inserted — A record was added or a category created.
• Item Updated — The value of a record field or a category field has changed. (Whether this refers to any field or to a specific field can be chosen as well. So the change of the value of a specified record or category field can activate a trigger.)
Similar event types can be chosen for selected records or categories. Event types set for a selected category or record are:
• Item Deleted — The selected record or category was deleted.
• Item Updated — The value of a record field or a category field has changed. (Whether this refers to any field or to a specific field can be chosen as well. This means that the change of a value of a specified record or category field can activate a trigger.)
The Trigger Actions available depend on the Cumulus Server you are connected to. Available actions are stored in a special folder. The following preconfigured trigger actions are included:
• Apply Metadata Template: a specified metadata template is applied when the action is triggered by any event
• Apply Permissions Template: a specified permission template is applied when the action is triggered by any event
• Mail Notifier: an email is sent to one or more specified recipients when the action is triggered by any event.
• Rename Asset: the asset is renamed when the action is triggered by any event.
• Run Asset Action: a specified asset action is performed when the action is triggered by any event.
• Start Workflow: a specified workflow is started when the action is triggered by an Item Updated event, and a specific condition defined by a query is met.
Note that such a query must be created manually. It is not possible to use a previously saved query! The most convenient way to create a query is to compose it in the Cumulus Desktop Client’s Find window in Advanced Mode, then copy it into the Query to match field of the Configure Module window.
BACKGROUND INFO: More Trigger Actions
The Trigger Actions are based on modules which are implemented as ESPs. If you want to have more Trigger Actions available, contact Canto Professional Services or your Canto partner on how to develop an ESP that ’shows up’ as a Trigger Action.
PRECONDITIONS: Triggers can be created, edited or enabled/disabled only by users who are allowed to do so. To edit or create triggers, the user needs – depending on the kind of trigger – one or all of the following permissions:
• Manage Catalog Triggers
• Manage Record Triggers
• Manage Category Triggers
These permissions are set for the user in the User Manager (Permissions > Application Permissions.) With Enterprise, these permissions can also be set as Record or Category permissions for selected records or categories. Remember that Record or Category permissions for selected records or categories expand the record or category permissions a user has for the catalog in general.
The Trigger Administrator permission (set under Permissions > Administrator Permissions) allows a user to manage all triggers for a catalog. A user with this permission gets an additional option displayed in the Properties dialog for a record, category or catalog, Show All Triggers. If this option is enabled, all triggers are displayed to the user as well as an additional column displaying the name of the user who ‘owns’ the trigger (i.e., the user who created it.)