Publish Trigger

This trigger publishes the current asset in workflow, if it is able to be published, to all of its available destinations. Additionally, you can create custom workflows that publish content only to specified destinations by passing parameters to the trigger in the workflow definition. 

When using the publish trigger, remember that the system differentiates between standard transition steps and system steps. System steps that call the publish trigger continue to publish out content as the implicit system user (which operates as an administrator-level user), whereas transition steps consider the role of the current user who has ownership of the step.

If a publish trigger is executed during a transition step, a user with an Approver role, for example, would not have sufficient privileges to publish out the content.

Implementation

Declaration

Usage

Parameters

Note that specifying these parameters is completely optional. Unless you specify, the system will publish to all applicable destinations. This is only for administrators wanting to publish to a subset of the applicable destinations for a given workflow definition.

destination

You can specify multiple destinations by putting in multiple parameter nodes, each containing a name and value tag, such as:

Please note that the path to the destination is case sensitive.

working-copy-publish

It is also possible to publish the working copy of a page in workflow for staging purposes. This can be accomplished by adding a working-copy-publish parameter to the invocation of the publish trigger in a workflow definition with a value of true. By default (without this parameter) only the non-working copy version of the asset in workflow is published. 

Adding a Workflow Trigger

The Cascade Server workflow builder utilizes centrally managed triggers.  For a trigger to be available in a workflow created by the Workflow Builder, the trigger must first be defined and assigned a name in the system-wide trigger base.  Defining triggers in this way allows the Java files that contain each trigger’s functionality to be referenced later in the workflow definition.

If a new custom trigger has been written or Cascade Server has been upgraded without including the default database, the new triggers will need to be added before they become available in the Workflow Builder.

To add a workflow trigger:

  1. In the Administration area, select ‘Workflow Definitions’.
  2. Click ‘Manage Workflow Triggers’.
  3. All currently available triggers in the default database are shown, along with the ‘Add a Trigger’ field.
  4. Type in the name of the new trigger and click ‘Submit’.
  5. The new trigger will now appear on the list of available triggers and will be available for use within the Workflow Builder.

manage workflow triggers

Adding a trigger using this interface ensures that the triggers will be defined in all workflows created using the Workflow Builder.  For workflows created without the Workflow Builder, triggers must be defined individually for each workflow.

See Also