About Workflow

A JIRA workflow is the set of steps (or statuses) and transitions that an issue goes through during its lifecycle. Workflows typically represent business processes.

JIRA ships with a default workflow called 'jira'. This default workflow cannot be edited, but you can customise the issue lifecycle by creating additional workflows. Each workflow can be associated with particular projects and (optionally) particular issue type(s).


JIRA's default workflow

About Steps and Transitions

JIRA workflows consist of steps and transitions:

  • A step represents a workflow's current status for an issue. An issue can exist in one step only at any point in time. Each workflow step corresponds to a 'linked status'. When an issue is moved into a particular step, its 'Status' field is updated to the value of the step's 'linked status'. In the diagram above, the blue boxes represent steps/statuses.
    When defining a step, you can optionally specify properties, one of which allows you to make an issue uneditable while it is in that step.
    (tick) Although steps and statuses are treated separately when administering workflows, they are effectively synonymous concepts in JIRA and as such, it usually helps to name a step after its linked status.
  • A transition is a link between two steps. A transition allows an issue to move from one step to another step. For an issue to be able to progress from one particular step to another, a transition must exist that links those two steps. Note that a transition is a one-way link, so if an issue needs to move back and forth between two steps, two transitions need to be created. In the diagram above, the arrows represent transitions.
    The available workflow transitions for an issue are listed on the issue's 'View Issue' page. A user can execute a transition (i.e. move the issue through workflow) by clicking one of the available links, e.g.:

    When defining a transition, you can optionally specify:
    • A screen to be displayed to the user — this is useful if you need the user to provide input before completing the transition.
    • Conditions — these control who can perform a transition (i.e. who can see the transition link on the 'View Issue' page).
    • Validators — these check that any user-supplied input is valid before performing the transition.
    • Post Functions— these perform particular actions after the transition is complete, e.g.:
      • Assign the issue to a particular user.
      • Send an email notification.
      • Update a field in the issue.

On this page:

See also:

About 'Open' and 'Closed' Issues

Within JIRA (e.g. in the 'Assigned To Me' gadget and other gadgets), an issue is determined to be 'open' or 'closed' based on the value of its 'Resolution' field — not its 'Status' field.

This is true regardless of the current value of the issue's 'Status' field ('OPEN', 'IN PROGRESS', etc).

So if you need your workflow to force an issue to be 'open' or 'closed', you will need to set the issue's 'Resolution' field during a transition. There are two ways to do this:

Creating a Workflow

  1. Log in as a user with the 'JIRA Administrators' global permission.
  2. Select 'Administration' > 'Issues' > 'Workflows' to open the 'View Workflows' page, which shows a list of all existing workflows in your system.
    (tick) Keyboard shortcut: 'g' + 'g' + start typing 'workflows'
  3. Create a new workflow in JIRA using either of the following methods:
  4. Once you have created your new workflow you may want to customise it using the Workflow Designer by adding and/or editing steps and transitions (below) — especially if you have created a blank workflow.
  5. When you have finished customising your new workflow, see Activating Workflow for details on how to use it with a JIRA project.

Editing a Workflow

Editing a workflow means that you are modifying the steps and transitions that make up a workflow. Read more about steps and transitions on this page.

The process for editing a workflow differs depending on whether you are editing an inactive workflow or an active workflow. Restrictions are placed on the modifications you can make to an active workflow, due to the impact the changes will have on projects and/or issue types that the workflow is applied to.

Editing an Inactive Workflow

An inactive workflow is a workflow that is not currently being used by any projects.

Because there are no issues currently transitioning through an inactive workflow, you can simply use the Workflow Designer to edit the workflow's steps and transitions (below).

Editing an Active Workflow

An active workflow is a workflow that is currently being used by one or more projects.

To edit an active workflow, you must first create a 'draft' of it. You can then:

To edit an active workflow:

  1. Log in as a user with the 'JIRA Administrators' global permission.
  2. Select 'Administration' > 'Issues' > 'Workflows' to open the 'View Workflows' page, which shows a list of all existing workflows in your system as shown under Creating a workflow (above).
    (tick) Keyboard shortcut: 'g' + 'g' + start typing 'workflows'
  3. Do one of the following to create your draft:
  4. After using the Workflow Designer or the 'View Workflow Steps' page to add and/or edit your draft workflow's steps and transitions (below), click 'Publish' at the top right of the Workflow Designer (or the 'publish this draft' link in the information message box near the top of the 'View Workflow Steps' page). A confirmation dialog box (or confirmation page if you used the 'View Workflow Steps' page) will be displayed:
  5. Select whether you wish to save the original workflow as an inactive copy. If you choose to retain the original workflow, enter a name for the inactive copy.
  6. Click 'Publish' to publish your draft (i.e. commit your changes to the active workflow).

(info) Please Note:

Limitations

Please note that the following limitations apply when editing an active workflow (i.e. draft):

If you wish to make any of the modifications listed above, then you will need to copy the workflow (see Creating a Workflow above), modify the copy and then activate it. Please note, this method will be significantly slower than editing an active workflow, particularly for large instances of JIRA.

Using the Workflow Designer

The Workflow Designer allows you to visualise the entire layout of your workflow as well as create and edit a workflow's steps and transitions visually.

The Workflow Designer's interface consists of the four areas indicated in the following diagram.

(info) Please Note:

Using the Main Toolbar

The Main Toolbar contains tools (on buttons) for visually arranging your workflow's steps/statuses and transitions on the Workflow Design Area.

Button

Description

Select Tool
Selects, moves or edits any item on the Workflow Design Area. Selected items are highlighted in red. Click away from any item in the Workflow Design Area to clear the selection.

Create Transition — Straight Line
Creates a transition with a single straight line. See Adding a Transition (below) for details.

Create Transition — Polygonal Line
Creates a transition with multiple straight lines. See Adding a Transition (below) for details.

Create Transition — Bezier Line
Creates a transition with a curved line. See Adding a Transition (below) for details.

Create Annotation
Adds a 'sticky note' to the Workflow Design Area into which you can write a short description or annotation to add to your workflow's layout.
(info) Annotations only appear in the Workflow Design Area and are not visible when viewing workflows from the 'View Issue' page (by clicking the 'View Workflow' link).

Zoom In

Zoom Out

Save Layout
Saves the current position of all items on the Workflow Design Area (including steps, transitions and annotations).
(info) If you have moved items around on the Workflow Design Area and wish to save their positional layout, do not forget to use this feature before leaving the Workflow Designer.

Load Saved Layout
Loads the previously saved positional layout of all items on the Workflow Design Area.

Auto Layout
Repositions all items on the Workflow Design Area automatically.

Save Snapshot Image
Saves an image of the current position of all items on the Workflow Design Area in PNG format.

Toggle Transition Labels
Switches between hiding or revealing transition labels, each of which indicate their 'Transition (id)'.
(info) To be able to edit all aspects of a transition (including its conditions, validators, post functions and properties), Transition Labels must be visible. If Transition Labels are hidden, you can only edit the 'Transition Name', 'Description', 'Destination Step' and 'Transition View' of a transition by double-clicking its transition line. See the 'Add Workflow Transition' page (below) for details.

Using the Statuses Panel

The Statuses Panel lists all available JIRA statuses which have not already been associated with a step on the Workflow Design Area. It also provides tools (on buttons) for adding new statuses or editing existing ones.

Button

Description

Refresh List
Refreshes the statuses list.

Add New Status
Adds a new global status to JIRA. See Defining 'Status' Field Values for details.

Status Editor
Opens the 'Status Editor' which allows you to edit an existing global status in JIRA. See Defining 'Status' Field Values for details.

(tick) You can use the Statuses Panel to add a step to your workflow. See Adding a Step (below) for details.

Using the Global Transitions Panel

The Global Transitions Panel lists all global transitions used in your workflow. A global transition is one in which the destination step of the transition has all remaining steps in the workflow as incoming steps, but provides the added advantage of only requiring you to edit or update the transition in one place.

(info) Please Note:

The Global Transitions Panel also provides tools (on buttons) for adding new global transitions, as well as editing or deleting existing ones.

Button

Description

Add New Transition
Adds a new global transition to the workflow. See Adding a Transition (below) for details.

Edit Selected Transition
Edits the currently selected global transition in the global transitions panel. See Editing a Transition (below) for details.

Delete Selected Transition
Deletes the currently selected global transition in the global transitions panel, from the workflow.

Using the Workflow Design Area

The Workflow Design Area shows the layout of your workflow's steps as well as transitions, consisting of transition lines and labels.

Use the 'Select Tool' (above) to move these items around Workflow Design Area.

(warning) Please Note:

Editing or Deleting Annotations

Once you have added an annotation using the 'Create Annotation' tool (above), you can do the following to edit or delete the annotation:

Accessing the Workflow Designer

To access the Workflow Designer for any workflow:

  1. Log in as a user with the 'JIRA Administrators' global permission.
  2. Select 'Administration' > 'Issues' > 'Workflows' to open the 'View Workflows' page, which shows a list of all existing workflows in your system.
    (tick) Keyboard shortcut: 'g' + 'g' + start typing 'workflows'
  3. Click the 'Design' link associated with the relevant workflow. The Workflow Designer is displayed, showing your workflow's steps and transitions.

Working with Steps

Adding a Step

To add a new step to a workflow:

  1. Log in as a user with the 'JIRA Administrators' global permission.
  2. Select 'Administration' > 'Issues' > 'Workflows' to open the 'View Workflows' page, which shows a list of all existing workflows in your system as shown under Creating a workflow (above).
    (tick) Keyboard shortcut: 'g' + 'g' + start typing 'workflows'
  3. Use either the Workflow Designer or the 'View Workflow Steps' page to add the new step to the workflow.

Using the Workflow Designer to add the new step

  1. On the 'View Workflows' page, click the 'Design' link next to the workflow that you wish to add a step to. The 'Workflow Designer' page is displayed, showing your workflow's existing steps as well as the lines and labels of transitions between these steps (in the Workflow Design Area).
  2. Drag an available status from the Statuses Panel list and drop it onto the Workflow Design Area. A new step will be added to your workflow.

    (info) Please Note:

Using the 'View Workflow Steps' page to add the new step

  1. On the 'View Workflows' page, click the 'Steps' link next to the workflow that you wish to add a step to. The 'View Workflow Steps' page is displayed, showing the existing steps that make up the workflow and each step's Linked Status and Outgoing Transitions (under 'Transitions (id)').
    (info) The 'Add New Step' form appears below the list of steps. However, this will only be shown if the workflow is inactive or you are editing the draft of an active workflow.
  2. In the 'Step Name' field, type a short name for the step.
    (tick) It is often useful to use the name of the corresponding linked status (in the following step).
  3. In the 'Linked Status' field, select the status that corresponds to this step.
    (info) Each status can only correspond to one step in each workflow. Hence, if all statuses are linked to steps in this workflow, you may need to define a new status.
  4. Click the 'Add' button. The 'View Workflow Steps' page will now show your new step in the list.

(info) Be aware that some gadgets (such as Assigned To Me and In Progress) will not display data for issues in and after the "Resolved" step.

Editing a Step

To edit an existing step in a workflow:

  1. Log in as a user with the 'JIRA Administrators' global permission.
  2. Select 'Administration' > 'Issues' > 'Workflows' to open the 'View Workflows' page, which shows a list of all existing workflows in your system as shown under Creating a workflow (above).
    (tick) Keyboard shortcut: 'g' + 'g' + start typing 'workflows'
  3. Click the 'Steps' link next to the workflow whose step you wish to edit. The 'View Workflow Steps' page is displayed, showing the steps that make up the workflow (as shown under Adding a Stepabove).

Using Step Properties

You can use a workflow step's properties to prevent issues from being edited when they are at that particular workflow step. For example, in the default workflow (above), issues in the 'Closed' step/status cannot be edited, even by users who have the 'Edit Issue' permission.

(info) Please Note:

To stop issues from being editable in a particular workflow step, set the step's 'jira.issue.editable' property to 'false' as follows:

  1. Log in as a user with the 'JIRA Administrators' global permission.
  2. Select 'Administration' > 'Issues' > 'Workflows' to open the 'View Workflows' page, which shows a list of all existing workflows in your system as shown under Creating a workflow (above).
    (tick) Keyboard shortcut: 'g' + 'g' + start typing 'workflows'
  3. Use either the Workflow Designer or the 'View Workflow Steps' page to set the workflow step's property.

Using the Workflow Designer to set the step's property

  1. On the 'View Workflows' page, click the 'Design' link next to the workflow whose step you wish to make uneditable. The 'Workflow Designer' page is displayed, showing the steps that make up your workflow in the Workflow Design Area (as shown under Using the Workflow Designer above).
  2. In the Workflow Design Area, move the mouse pointer over the relevant step and click the cog icon that appears to the right of the step to reveal a popup menu.
  3. From the popup menu, select 'Issue Editable' to remove the tick from that menu item. This action sets the step's jira.issue.editable property and its value to false.
    (info) Please Note:

Using the 'View Workflow Steps' page to set the step's property

  1. On the 'View Workflows' page, click the 'Steps' link next to the workflow whose step you wish to make uneditable. The 'View Workflow Steps' page is displayed, showing the steps that make up the workflow (as shown under Adding a Step above).
  2. Click the 'View Properties' link that corresponds to the relevant step. The 'View Workflow Step Properties' page is displayed, showing the step's existing properties (if any). The 'Add New Property' form appears below the list of existing properties (if any have already been defined).
    (info) The 'Add New Property' form will not appear if the step's workflow is not editable.
  3. In the 'Property Key' field, type: jira.issue.editable
  4. In the 'Property Value' field, type: false
  5. Click the 'Add' button.

(info) It is not possible to edit a step's properties on this page. To change any property's key or value (or both), you must first delete the property you wish to change and add the new updated property.

Deleting a Step

(info) Please Note: A step can only be deleted if it has no incoming transitions. Also note that you cannot delete a step from an active workflow — see Limitations for a workaround.

To delete a step from a workflow:

  1. Log in as a user with the 'JIRA Administrators' global permission.
  2. Select 'Administration' > 'Issues' > 'Workflows' to open the 'View Workflows' page, which shows a list of all existing workflows in your system as shown under Creating a workflow (above).
    (tick) Keyboard shortcut: 'g' + 'g' + start typing 'workflows'
  3. Use either the Workflow Designer or the 'View Workflow Steps' page to delete the step from the workflow.

Using the Workflow Designer to delete the step

  1. Click the 'Design' link next to the workflow whose step you wish to delete. The 'Workflow Designer' page is displayed, showing the steps that make up your workflow in the Workflow Design Area (as shown under Using the Workflow Designer above).
  2. In the Workflow Design Area, move the mouse pointer over the relevant step and click the cog icon that appears to the right of the step to reveal a popup menu.
  3. From the popup menu, select 'Delete Step' to remove the step from the workflow.

Using the 'View Workflow Steps' page to delete the step

  1. Click the 'Steps' link next to the workflow whose step you wish to delete. The 'View Workflow Steps' page is displayed, showing the steps that make up the workflow (as shown under Adding a Step above).
  2. Click the 'Delete Step' link that corresponds to the relevant step.
    (info) This link will only be shown if the step has no incoming transitions.

Working with Transitions

Adding a Transition

To add a transition to a workflow:

  1. Log in as a user with the 'JIRA Administrators' global permission.
  2. Select 'Administration' > 'Issues' > 'Workflows' to open the 'View Workflows' page, which shows a list of all existing workflows in your system as shown under Creating a workflow (above).
    (tick) Keyboard shortcut: 'g' + 'g' + start typing 'workflows'
  3. Use either the Workflow Designer or the 'View Workflow Steps' page to add the transition to the workflow.
    (tick) The Workflow Designer provides more options for creating your new transition.

Using the Workflow Designer to Add the Transition

  1. On the 'View Workflows' page, click the 'Design' link next to the workflow you wish to add a transition to. The 'Workflow Designer' page is displayed, showing your workflow's existing steps as well as the lines and labels of transitions between these steps (as shown under Using the Workflow Designer above).
  2. Click the appropriate 'Create Transition' button in the Workflow Designer's Main Toolbar (above), according to the type of transition line you wish to create.
  3. In the Workflow Design Area, click the step that will be the Originating Step of the transition.
  4. Click the step that will be the Destination Step of the transition. The 'Add Transition' dialog box opens.
  5. Choose between creating a new transition ('New Transition'), copying an existing transition ('Clone Transition') or using a 'common transition' ('Use Common Transition').
  6. Click the 'OK' button to complete the addition of your transition.

Using the 'View Workflow Steps' Page to Add the Transition

  1. On the 'View Workflows' page, click the 'Steps' link next to the workflow you wish to add a transition to. The 'View Workflow Steps' page is displayed, showing the existing steps that make up the workflow and each step's Linked Status and Outgoing Transitions (under 'Transitions (id)').
  2. Identify the step from which your new transition will originate and click the 'Add Transition' link next to the step. The 'Add Workflow Transition' page is displayed.
  3. In the 'Transition Name' field, type a short name for the transition.
    (info) This name will be shown to users as the transition link in the list of 'Available Workflow Actions' on the 'View Issue' page.
  4. (Optional) In the 'Description' field, type a short description of the purpose of the transition.
  5. In the 'Destination Step' field, choose the step to which issues will move when this transition is executed.
  6. In the 'Transition View' field, select either:

Editing or Deleting a Transition

To edit or delete an existing transition of a workflow:

  1. Log in as a user with the 'JIRA Administrators' global permission.
  2. Select 'Administration' > 'Issues' > 'Workflows' to open the 'View Workflows' page, which shows a list of all existing workflows in your system as shown under Creating a workflow (above).
    (tick) Keyboard shortcut: 'g' + 'g' + start typing 'workflows'
  3. Use either the Workflow Designer or the 'View Workflow Steps' page to edit or delete the transition of the workflow.

Using the Workflow Designer to edit or delete the transition

  1. On the 'View Workflows' page, click the 'Design' link next to the workflow whose transition you wish to edit or delete. The 'Workflow Designer' page is displayed, showing your workflow's existing steps as well as the lines and labels of transitions between these steps (as shown under Using the Workflow Designer above).
  2. In the Workflow Design Area, move the mouse pointer over the relevant transition label and click the cog icon that appears to the right of the label to reveal a popup menu.
  3. From the popup menu, you can:

Using the 'View Workflow Steps' page to edit or delete the transition

  1. On the 'View Workflows' page, click the 'Steps' link next to the workflow whose transition you wish to edit or delete. The 'View Workflow Steps' page is displayed, showing the existing steps that make up the workflow and each step's Linked Status and Outgoing Transitions in the 'Transitions (id)' column (as shown under Adding a Transition above).
  2. In the 'Transitions (id)' column, click the link of the Outgoing Transition of the step you wish to edit. The 'View Workflow Transition' page is displayed.

    On the 'View Workflow Transition' page, the following information is shown about the transition:
  3. On the 'View Workflow Transition' page, you can:

Using a Screen with a Transition

When a user clicks a particular transition, a screen can be used to gather input from the user before the transition is executed.

Example: Using a Screen to Set the 'Resolution' Field

For a particular step in a workflow, you might need to create a transition that will move the issue to a 'closed' status (e.g. 'CLOSED', 'RESOLVED', etc) - see 'open' and 'closed' issues. As part of this transition, you might need the user to set the 'Resolution' field. To do this:

  1. (Optional) Create a screen (e.g. named 'Resolution Screen'), that contains the 'Resolution' field (and any other fields you want to show). See Defining a Screen for details.
    (tick) JIRA already includes a screen named 'Resolve Issue Screen', which contains the 'Resolution', 'Fix Version/s', 'Assignee' and 'Log Work' fields.
  2. Create or edit your transition and then choose the screen that contains the 'Resolution' field (e.g. 'Resolution Screen') in the 'Transition View' field:

Applying Conditions to Transitions

Conditions control who can perform a transition and the circumstances under which they can perform the transition (such as their project permissions, the status of any sub-tasks, or the state of source code associated with issues).

If any part of a transition's condition fails, the user will not see the transition link on the 'View Issue' page.

JIRA's built-in conditions

JIRA includes the following individual conditions, which can be added immediately to any transition:

Condition

Description

Additional Parameters Required

Only Assignee Condition

Only allow the issue's current assignee to execute the transition.

None

Only Reporter Condition

Only allow the issue's reporter to execute the transition.

None

Permission Condition

Only allow users with a given permission to execute the transition.

A project-wide permission

Sub-Task Blocking Condition

Only allow a parent issue's transition to execute if all its sub-tasks have at least one of a specified set of statuses.

One or more statuses

User Is In Group

Only allow users in a given group to execute the transition.

A group

User Is In Group Custom Field

Only allow users in a given group-type custom field to execute a transition.

A custom field of type "Group"

User Is In Project Role

Only allow users in a given project role to execute a transition.

A project role

Code Committed Condition

Only allow the transition to execute if code either has or has not been committed against the issue.

Specify whether or not code must be committed

No Open Reviews Condition

Only allow the transition to execute if no related Crucible reviews are still open against the issue.

None

Unreviewed Code Condition

Only allow the transition to execute if no unreviewed changesets related to the issue exist.

None

(info) You can also create your own conditions via the plugin system. See the Workflow Plugin Guide for details.

Adding a Condition

To add a condition to a transition:

  1. Log in as a user with the 'JIRA Administrators' global permission.
  2. Select 'Administration' > 'Issues' > 'Workflows' to open the 'View Workflows' page, which shows a list of all existing workflows in your system as shown under Creating a workflow (above).
    (tick) Keyboard shortcut: 'g' + 'g' + start typing 'workflows'
  3. Use either the Workflow Designer or the 'View Workflow Steps'  page to add the condition to the transition.
  4. Click the 'Add' link (in the 'Conditions' section). A list of all available conditions is displayed. See above for a list of JIRA's built-in conditions.
  5. Select a condition from the list and click the 'Add' button.
    (info)If the condition requires additional parameters (e.g. the name of a group or project role), the 'Add Parameters To Condition' dialog box/page will be presented.
  6. The 'Conditions' tab is displayed again, showing your new condition at the bottom of the list of conditions.
    (info)From here, you can:

Combining Conditions into Groups

You can construct complex conditions by combining two or more 'individual conditions' (added using the procedure above) using AND or OR boolean logic to form a 'grouped condition'. For example, the following simple grouped condition could be constructed:

This grouped condition will only be true (and hence, allow execution of the transition) if the user is the assignee of the issue AND the same user is in the jira-users group.

An overall 'complex condition' can be constructed for your transition by combining multiple grouped conditions using AND or OR boolean logic or even nesting grouped conditions. A transition with a complex condition (as such), can only be executed if all individual and grouped conditions that constitute the complex condition, have been satisfied, e.g:

Converting an Individual Condition into a Grouped Condition

To convert an individual condition into a grouped condition:

  1. Follow the Adding a Condition procedure (above) to step 3.
  2. Instead of clicking the 'Add' link at step 4, click the 'Add grouped condition' link of the individual condition you wish to convert into a grouped condition.
  3. Continue on from step 5.
    (tick) Please Note:

(warning) Please Also Note: It is not possible to add an individual condition that is separate from the outermost grouped condition. Clicking the 'Add' button only adds an individual condition to the outermost grouped condition. Bear this in mind when creating a complex condition and refer to JRA-25179 for more information.

Adding Individual Conditions to a Grouped Condition

To add an individual condition to a grouped condition:

  1. Follow the Adding a Condition procedure (above) to step 3.
  2. Instead of clicking 'Add' link at step 4, click the 'Add condition to group' link associated with the grouped condition you want to add your individual condition to.
  3. Continue on from step 5.
Switching a Grouped Condition's Logic

The logic of all individual conditions within a grouped condition can be switched between AND and OR. To do this, simply click the 'Switch to OR' or 'Switch to AND' link associated with the grouped condition whose logic you wish to switch.

(info) If you need to switch the logic of only some (not all) individual conditions within a grouped condition, create a nested grouped condition as described above.

Applying Validators to Transitions

Validators check that any input available to the transition (such as user-supplied input) is valid before the transition is performed. For example, a validator can be used to ensure that the comment entered by a user on a transition's screen meets a certain project permission criterion.

If a transition's validator 'fails', the transition's Post Functions will not be executed and the issue will not progress to the destination step of the transition.

JIRA ships with a couple of default validators that validate whether or not the user who performed the transition had a particular project permission, which can be added immediately to any transition.
(info) You can also create your own validators via the plugin system.

(info) How do validators differ from conditions?

Adding a Validator

To add a validator to a transition:

  1. Log in as a user with the 'JIRA Administrators' global permission.
  2. Select 'Administration' > 'Issues' > 'Workflows' to open the 'View Workflows' page, which shows a list of all existing workflows in your system as shown under Creating a workflow (above).
    (tick) Keyboard shortcut: 'g' + 'g' + start typing 'workflows'
  3. Use either the Workflow Designer or the 'View Workflow Steps'page to add the validator to the transition.
  4. Click the 'Add' link (in the 'Validators' section). A list of all available validators is displayed.
  5. Select a validator from the list and click the 'Add' button.
    (info)If the validator requires additional parameters (e.g. the name of a group or project role), the 'Add Parameters To Validator' dialog box/page will be presented.
  6. The 'Validators' tab is displayed again, showing your new validator at the bottom of the list of validators.
    (info)From here, you can:

(info) Please Note:

Applying Post Functions to Transitions

Post functions carry out any additional processing required immediately after a transition is executed, such as updating an issue's fields, generating change history for an issue, adding a comment to an issue, or generating an event such as an email notification. There are two categories of post functions in JIRA — essential and optional.

Essential Post Functions

JIRA includes the following 'essential' post functions, which are automatically added to every newly-created transition and performed in this order:

Essential post function

Set issue status to the linked status of the destination workflow step.

Add a comment to an issue if one is entered during a transition.

Update change history for an issue and store the issue in the database.

Re-index an issue to keep indexes in sync with the database.

Fire an event that can be processed by the listeners.

These 'essential' post functions cannot be deleted from a transition or reordered relative to each other, as this could compromise other issue functionality within JIRA. However, you can insert other (optional) post functions around or between them.

Optional Post Functions

JIRA includes the following optional post functions which can be added to transitions:

Optional post function

Description

Assign to Current User

Assigns the issue to the user who is executing the transition.
(info) This post function will be ignored unless the user has the 'Assignable User' permission. You may want to use a condition to ensure that the logged-in user has this permission before executing the transition.

Assign to Lead Developer

Assigns the issue to the component lead (if one exists) or project lead.

Assign to Reporter

Assigns the issue to the user who created the issue.

Create Perforce Job Function

Creates a Perforce Job (if required) after completing the workflow transition.

Update Issue Field

Updates one of the issue's fields to a given value. Fields which can be updated include:

  • Assignee
  • Description
  • Environment
  • Priority
  • Resolution
  • Summary
  • Original Estimate
  • Remaining Estimate

    (info) Note that this post function cannot update custom fields.

(info) You can also create your own post functions via the plugin system. See the Workflow Plugin Guide for details.

Note that the four optional post functions must be positioned before the 'Update change history for an issue and store the issue in the database' post function (above), with the exception of the 'Create' transition.

The Initial Transition ('Create' or 'Create Issue')

When creating an issue, it is sometimes useful to be able to perform specific processing tasks (such as setting a particular field's value). You can perform such tasks by adding post functions to the workflow's 'initial transition'.

The 'initial transition' is executed whenever a user creates an issue, which in turn, places the newly-created issue into the workflow's 'initial step'. Every workflow has only one 'initial step', which is the first step in the issue's workflow and is the 'initial step's' first incoming transition. By default:

JIRA includes the following 'essential' post functions which are specific to a workflow's 'initial transition'. These post functions are automatically added to this transition of every newly-created workflow (and performed in this order):

Essential post function ('initial transition' only)

Creates the issue originally.

Fire an event that can be processed by the listeners.

The optional post functions (above) can also be added to a workflow's initial transition, as well as the following optional post functions (which, with the exception of 'Store Issue', are essential to all other newly-created transitions):

Optional post function ('initial transition' only)

Description

Create Comment

Adds a comment to an issue if one is entered during a transition.

Re-index Issue

Re-indexes an issue to keep JIRA's indexes in sync with the database.

Update Issue Status

Sets the issue's status to the linked status of the destination workflow step.

Store Issue

Stores updates to an issue (no change history is created).

(warning) Please exercise caution when adding one of these optional post functions to your 'initial transition'. A bug in JIRA (JRA-25070) currently prevents these post functions from being deleted once they have been added.

Optional post functions added to the workflow's 'Create' transition (for example, an 'Update Issue Field' transition to set the 'Assignee' field to a particular user when an issue is created), must be placed before the 'Creates the issue originally' post function.

Special case:

If you need to set the 'Resolution' field when creating an issue, add the 'Update Issue Field' post function after the 'Creates the issue originally' post function and after that, use the 'Store Issue' post function. The 'Store Issue' post function is useful for setting the 'Resolution' field during issue creation.
(warning) However, keep use of the 'Store Issue' post function to a minimum, since this post function:

Adding a Post Function

To add a post function to a transition:

  1. Log in as a user with the 'JIRA Administrators' global permission.
  2. Select 'Administration' > 'Issues' > 'Workflows' to open the 'View Workflows' page, which shows a list of all existing workflows in your system as shown under Creating a workflow (above).
    (tick) Keyboard shortcut: 'g' + 'g' + start typing 'workflows'
  3. Use either the Workflow Designer or the 'View Workflow Steps'  page to add the post function to the transition.
  4. Click the 'Add' link (in the 'Post Functions' section). A list of all available post functions is displayed.
  5. Select a post function from the list and click the 'Add' button.
  6. If the post function requires one or more configuration parameters (e.g. the name of an event), the 'Add Parameters To Function' dialog box/page will be presented. Enter the appropriate information and click the 'Add' button.
  7. The 'Post Functions' tab is displayed again, showing your new post function at the bottom of the list of post functions.
    (info)From here, you can:

Using a Post Function to Set a Field

You can use a post function of type 'Update Issue Field' to set the value of an issue's field(s) after a particular transition is executed.

Example: Using a Post Function to Set the 'Resolution' Field

For a particular step in a workflow, you might need to create a transition that will move the issue to a 'closed' status (e.g. 'CLOSED', 'RESOLVED', etc) - see 'open' and 'closed' issues. As part of this transition, you might want to automatically set the 'Resolution' field. To do this:

  1. Create or edit  your transition (above).
  2. Add a new post function of type 'Update Issue Field' (above).
  3. Do the following on the 'Add Parameters to Function' page:
    1. Select 'Resolution' from the 'Issue Field' select list.
    2. Select a suitable resolution from the 'Field Value' select list.
  4. Click the 'Add' button and the transition's list of post functions will be displayed with your added post function highlighted in blue:

(info) To create a transition that clears the 'Resolution' field, follow the same steps above for adding an 'Update Issue Field' post function to your transition. However, on the 'Add Parameters To Function' page, select 'None' from the 'Field Value' select list.
The list of post functions for this transition will include the following statement:

Each time one of these transitions is executed, the 'Resolution' of the issue is automatically set or cleared as specified in these post functions.

Using a Post Function to Send a Notification

You can use the 'Fire an event that can be processed by the listeners' post function to fire the 'Generic Event', which is a built-in JIRA event that can be used to trigger the sending of email notifications after a particular transition is executed.

Alternatively, you could fire a custom event that you have created specifically for this transition.

When a transition is performed, JIRA will:

Example: Using a Post Function to Fire the 'Generic Event'

You can use the 'Generic Event' to send email notifications. To do this:

  1. Create or edit your transition (above).
  2. Click the transition's 'Post Functions' tab and edit the 'Fire an event that can be processed by the listeners' post function.
  3. On the 'Update parameters of the Fire Event Function for this transition' page, select 'Generic Event' from the list of events.

Working with Transition Properties

Properties are key-value pairs that are can be used to further customise transitions. For example, transition properties help to extend the default workflow (above) to allow language translations.

To view and edit the properties of a transition:

  1. Log in as a user with the 'JIRA Administrators' global permission.
  2. Select 'Administration' > 'Issues' > 'Workflows' to open the 'View Workflows' page, which shows a list of all existing workflows in your system as shown under Creating a workflow (above).
    (tick) Keyboard shortcut: 'g' + 'g' + start typing 'workflows'
  3. Use either the Workflow Designer or the 'View Workflow Steps' page to view and edit the properties of a transition.

Using the Workflow Designer to view and edit the properties of a transition

  1. On the 'View Workflows' page, click the 'Design' link next to the workflow whose transition properties you wish to view or edit. The 'Workflow Designer' page is displayed.
  2. In the Workflow Design Area, move the mouse pointer over the relevant transition label and click the cog icon that appears to the right of the label to reveal a popup menu.
  3. From the popup menu, select 'Transition Properties', which opens the 'Edit Properties' dialog box that allows you to view a list of the transition's existing properties and edit them.

    On the 'Edit Properties' dialog box, you can:

Using the 'View Workflow Steps' page to view and edit the properties of a transition

  1. On the 'View Workflows' page, click the 'Steps' link next to the workflow whose transition properties you wish to view or edit. The 'View Workflow Steps' page is displayed.
  2. In the 'Transitions (id)' column, click the name of the relevant transition. The 'View Workflow Transition' page is displayed.
  3. Click the 'View properties of this transition' link. The 'View Workflow Transition Properties' page is displayed listing the properties currently set up for the transition. You can this page to add and delete properties for this transition.
    (info) It is not possible to edit a transition's properties on this page. To change any property's key or value (or both), you must first delete the property you wish to change and add the new updated property.

(info) For more information on specific transition properties, refer to the Workflow Properties page.

Customising Workflow Transitions on the 'View Issue' Page

When viewing an issue, most of the operations and workflow transitions accessible to a user are available from a row of buttons towards the top of the issue, known as the 'Operations Bar'. As shown in the following screenshot, workflow transitions appear in the right-most set of buttons of the operations bar.


Screenshot: Workflow Transitions on the View Issue Page

By default, the first two transitions appear as separate buttons in the set of transition buttons. Any additional transitions 'spill over' into the 'Workflow' button dropdown menu. The order in which these buttons appear on the view issue page is based on the order of the default workflow (above), or for custom workflows, the order in which a JIRA administrator has added transitions to the custom workflow.

Hence, in the example above, the workflow transition order is: 'Start Progress' -> 'Resolve Issue' -> 'Close Issue'.

JIRA provides the ability to customise the appearance and order of these transitions on the View Issue page.

Changing the Number of Transition Buttons

To change the number of transition buttons from the default of two (with any remaining transitions spilling over into the 'Workflow' button dropdown menu):

  1. Shutdown JIRA.
  2. Edit the jira-config.properties file in your JIRA Home Directory.
    (info) See Making changes to the jira-config.properties file for more information.
  3. Change the value of the ops.bar.group.size.opsbar-transitions property to the number of transition buttons required before the 'Workflow' button.
    (info) If this property does not exist in your jira-config.properties file, add it. Otherwise, a default value of 2 is assumed.
  4. Save the updated jira-config.properties file.
  5. Restart JIRA.

Changing the Order of Transition Buttons and 'Workflow' Menu Items

To change the order of transition buttons, including additional transitions in the 'Workflow' dropdown menu on the 'View Issue' page, you need to add the property key opsbar-sequence to each workflow transition that you wish to re-order. Each opsbar-sequence property key requires a property value that defines the order of the transition action on issue views.

To add an opsbar-sequence property key and value to a workflow transition:

  1. Access the workflow transition's properties, as described in Working with transition properties (above).
  2. In the 'Add New Property' section of the workflow transition's 'View Workflow Transition Properties' page, type 'opsbar-sequence' into the 'Property Key' field.
  3. In the 'Property Value' field, type a positive integer value (starting at '0') that defines the order of the transition action on issue views.
    (tick) For each workflow transition, you may wish to use gaps in your opsbar-sequence property values (for example, 10, 20, 30, etc.) rather than consecutive values. This will allow you to 'insert' new workflow transitions more easily at a later point in time.
  4. Click the 'Add' button.

(info) Please Note: Be aware that adding the opsbar-sequence property to a workflow transition does not change the order of these transitions on the 'View Workflow Steps' page (above). The addition of this property only affects the order of transitions on the 'View Issue' page.

Using 'Common Transitions'

A 'common transition' is a transition that is defined only once in a given workflow but is used more than once in the same workflow. A common transition has more than one originating step leading to a single destination step, but provides the added advantage of only requiring you to edit or update the transition in one place.

(info) Please Note: Global transitions (above) are similar to common transitions and provide the same editing advantages. However, they differ from each other in the following respects:

You can create common transitions using the Workflow Designer by following these steps:

  1. Create a transition to a destination step as described in Adding a transition (above).
  2. Create another transition from another step to the same destination step, but in the 'Add Transition' dialog box, choose the 'Use Common Transition' option.
  3. In the 'Transition To Reuse' dropdown menu, select the transition you created in step 1 above.

You can edit existing common transitions via the 'View Workflow Steps' page, but as described in Adding a transition (above), they cannot be created.

If you are only able to use the 'View Workflow Steps' page to create or edit workflows, you can do either of the following to edit common transitions in a JIRA workflow:

Using XML to Create a Workflow

JIRA's workflow editor generates OSWorkflow XML definition files that are stored in JIRA's database. If you need to take advantage of an OSWorkflow-based feature that is not available in JIRA's workflow editor (such as 'common transitions' above), you can define the workflow in XML and then import it into JIRA as described below.

Once the XML workflow has been imported, JIRA's workflow editor should be able to display most OSWorkflow definitions even if it does not support creating or editing them.

For example, conditional results of workflow transitions are displayed in the 'Other' tab on the 'View Workflow Transition' page. (info) The 'Other' tab is only visible if a transition has elements that the editor does not directly support.

Importing an XML Workflow into JIRA

To import an XML workflow into JIRA:

  1. Log in as a user with the 'JIRA System Administrators' global permission.
  2. Select 'Administration' > 'Issues' > 'Workflows' to open the 'View Workflows' page, which shows a list of all existing workflows in your system as shown under Creating a workflow (above).
    (tick) Keyboard shortcut: 'g' + 'g' + start typing 'workflows'
  3. Locate the 'Add New Workflow' form at the bottom of the page and click the 'import a workflow from XML' link. The 'Import Workflow' page is displayed.
  4. In the 'Name' field, type a name (usually 2-3 words) to identify your new workflow.
  5. (Optional) In the 'Description' field, type a detailed description of your new workflow.
  6. Do either of the following:
  7. Click the 'Import' button.

Copying a Workflow Between Systems

Sometimes it is useful to create a workflow in a test system and then copy it into a production system. To do this:

  1. In the test system, export the workflow to XML by clicking the 'XML' link next to the workflow in the list shown on the 'View Workflows' page (above) and save the output into a file.
  2. In the production system, import the file via the 'import a workflow from XML' link as described in Using XML to create a workflow (above).

(minus) When importing an XML workflow into JIRA:

(minus) When copying a workflow between systems: