Practice Exams:

Atlassian Jira Administrator ACP-100 – Introduction and the Jira Atmosphere Part 4

  1. How to Create and Clone a Workflow

As a Jira admin, you create and modify the workflows. For your Jira instance, there are a few ways to get the workflow you need. You can create one from scratch, clone and edit an existing workflow, or import a workflow. In this video, we cover creating a workflow from scratch and cloning an existing workflow. Check out the Jira Administrator Reference guide for details on the import process. Perhaps you’re wondering, ring, should I create a new workflow from scratch or clone an existing one? Both options are available, but here’s why you might choose one over the other.

When you create a workflow from scratch, you build everything yourself and don’t need to evaluate or edit existing workflow options such as Conditions or validators. If you have a lot of experience with workflows, you may be able to easily put one together, whereas if you copied one, you’d be deleting as much as you added or edited. Almost invariably, copying an existing workflow is faster, especially if you only need a few changes. Additionally, it could help you understand the parts of a Jiro workflow if you’re unfamiliar. Do you think you’d create or clone a workflow for a user request? When you create a new workflow from scratch, you build in all statuses and transitions to that workflow.

There are two modes you can work in diagram a visual representation in a flowchart view and text a list of the statuses and transitions as text. Violet needs to create a new workflow for the development team to replace the simplified workflow and add in some workflow functions. We visit Workflow functions in later videos, but for now, let’s see how to create a workflow from scratch. Navigate to the workflows page and click Add workflow.

Then, in the Add Workflow window, add a name and description for your workflow and click Add. For example, we call this development Workflow and add a description. On the next page, you build your workflow, and you can do this in either a diagram or text mode. Click Add Status to add a new status to your workflow. For example, we add the In progress status. After adding a status, add a transition. For example, we add the Start Progress transition. We select a from status of open and a to status of in progress. Add additional statuses and transitions as needed. For this workflow, Violet needs an InDesign Review status and an Inky Way status to account for steps in the web development team’s process. To finish this workflow, we add a closed status with a transition of close.

Once you finish adding your statuses, you have an inactive workflow. You need to associate the workflow with a workflow scheme to make that workflow active. Still in Jira administration. Click workflow schemes. Find the scheme you want to edit, and then click Edit. On the Scheme page from the Add workflow menu, click Add Existing. Select the workflow you want to add, and associate with the appropriate issue types. Once you select the workflow and associate with issue types.

Click publish to publish it. If you want to copy an existing workflow, instead of creating one from scratch, first find a workflow you want to copy. Then, under Actions, click Copy, and then update your new workflow as needed with a new name and description and updated statuses and transitions. Before we wrap, let’s run down a few points about modifying workflows.

Any workflow not being used in a project in Jira is called Inactive. You can keep inactive workflows as backups or as in progress workflows as you build them. To make a workflow active, you need to be using it in one or more workflow schemes. You can’t technically edit an active workflow, but when you attempt to edit an active workflow, giro automatically creates a draft version, which you can edit, and when you are finished, you can publish the draft. At that time, you have the option to save your original workflow. As an inactive backup, it’s not possible to edit the workflow name, only the description if a workflow is active.

For drafts of active workflows, statuses cannot be deleted. And there are a few additional restrictions to what can be done to drafts of active workflows. If you need to make edits that Jira won’t allow, simply clone the workflow, modify the copy, and then activate it. If, after editing a workflow, you have issues using a status that is not in the new workflow, you may need to migrate those issues to a new status. We talk about using the Migration Wizard in another video. When you make changes to a workflow, you must publish them before you can see them. If you edit a workflow and don’t see your changes when you test, go back and make sure the workflow is part of that project’s workflow scheme. The workflow is published and the workflow is active.

  1. How to Configure Conditions and Validators

Conditions and validators are two of the four workflow functions available in Jira that let you extend workflow functionality. In this video, we talk about how to use conditions and validators in a workflow. Jira workflows include more than just statuses and transitions. They also include conditions, validators, post functions, and triggers. These workflow functions allow you to control an issue’s path through its lifecycle. For example, you can use conditions to make sure a person meets a certain requirement, such as a role before they see that Next status button. Conditions happen before a transition, validators happen during the transition, and post functions happen after.

Triggers work with external development tools to trigger an action within a workflow, such as transitioning to a new status out of the box. Jira comes with several workflow functions, and you can add more through apps such as ScriptRunner for Jira or Jira Suite utilities. In this video, we focus on conditions and validators. For information on post functions and triggers, check out that video too. Let’s get started with conditions. A condition acts as a gateway to a transition, controlling whether or not a user can see the transition button. Examples include block transition until approval, which means the user can’t transition the issue until someone approves it.

Workflow approvals are a service desk feature, but you can mimic this feature with other conditions, which we explain shortly. You could also use an only assignee condition, which means only the assignee of the issue can transition it. Violet needs to add a condition to the workflow used by the Finance and HR departments. Because these departments have Jira core projects, they lack the built in approval option in ServiceDesk workflows.

So Violet improvises using a condition that requires the user transitioning the issue to be part of the management group. Let’s see how Violet applies this condition. In the workflow, navigate to the Workflows page and locate the workflow you want to edit. Violet edits the business management workflow next to the workflow. Under actions, click edit. Then on the Edit page, you see a draft of the workflow. Locate the transition you plan to add a condition to, and we select the approved transition. Then, in the window that opens, click Conditions.

You see the Transition page, and on the Conditions tab, click Add Condition. On the Add Condition to Transition page, select the condition you want to apply to your transition, and we select the user is in group condition and click Add. This action opens another screen where we select the management group and to finish the change, publish the workflow. ScriptRunner Fjira allows you to add scripted conditions to your workflow, including the ability to make sure the issue matches a specific JQL query before the user can transition it. Check out our Getting Started with ScriptRunner for Jira Server course for more information on using scripted workflow functions.

Validators are another useful workflow function. A validator checks data before a transition is allowed to go through. If the validator fails, the issue doesn’t. Transition Jira includes one validator a permission validator to be sure a user has a specific permission. Unlike conditions, you can use apps to extend the validators in your instance. Gross Adventure uses apps to extend their validator capabilities. Violet needs to make sure that approvers enter a comment when they approve an issue in the business management workflow. This validator works alongside the condition requiring membership in the management group. To control the approval of particular requests. Violet uses a scripted validator from ScriptRunner to apply the necessary settings. On this transition, navigate to the Workflows page and when there, locate the workflow you want to edit. Violet edits the business management workflow next to the workflow under Actions, click Edit, and on the Edit page, locate the transition you plan to add a condition to.

We select the approved transition. In the window that opens, click Validators and you see the Transition page. On the validators tab, click add. Validator. Then on the Add Validator to Transition page, select the validator you want to apply to your transition. We select the script, validator and then click Add. This action opens another screen where we add the required parameters from the built in scripts. We select require a comment on transition. Then on the next page, we can add an optional note, which we do, and then click Update to finish the change. Publish the Workflow now that you’ve seen conditions and validators, think about how you might use them in your own instance.

  1. How to Configure Post Functions and Triggers

Post functions and triggers are additional workflow functions available in Jira. While post functions happen after a transition occurs and start an action, triggers work with development tools to help synchronize data between the tools in Jira. Let’s take a look at post functions first. Post functions occur after a successful transition. You can use post functions to automate actions that you want to happen after a transition, such as making sure the appropriate assignee gets the issue after the transition completes. A post function only carries forward if the transition is successful if it doesn’t fail validation. For example, some of the options for post functions include update a field with information, assign a specific user to the issue, or assign to the issue reporter.

Jira comes with several post functions, but if you need more, check out apps in the marketplace, including Jira Suite, Utilities, or Script Runner. For Jira, every transition includes five automatic post functions that you can’t remove or reorder. These post functions are called Essential post functions. Any other post functions are optional, and you can add and remove them as needed. Violet needs to set a post function on the Center Design Review transition in the development workflow that changes the assignee of the issue to the lead developer of the component. In this case, the component is Design and the lead developer is Liberty Sloan.

First, navigate to the Workflows page. When there locate a workflow you want to update and click Edit. And for our example, we select the Development workflow. On the edit page. You see a draft of the workflow, locate the transition you plan to add a post function to, and we select the Send to Design Review Transition because we want to switch the assignee to the lead developer of the Design component. In the window that opens, click Post Functions and you see the Transition page. On the Post Functions tab, click Add Post Function, and on the Add Post function to Transition page, select the Post function you want to apply to your transition.

We select the assigned to Lead Developer Post function and then click Add. There are no additional actions to take for this post function. To finish the change, publish the workflow. Now we need to test this post function. On the WD One issue, we have the appropriate team member listed as the lead developer for the design component already. To test. We go to the web development project and open the WD one issue. We click the Center Design Review button to move the issue to Design Review, and we see the assignee changes to Liberty Sloan. Triggers are designed for developers to automate the synchronization of data between development tools and Jira. A typical scenario where you might use triggers is to stop relying on developers to update issues status in Jira after committing code. Instead, you use a trigger in the workflow to automatically transition the issues based on events happening in the development tools. You can also use triggers to automatically transition issues and create subtasks when a developer creates a branch in the source code repository, the Web development team at Great Adventure needs to use a trigger in their workflow to provide some automation as they complete code in Bitbucket.

Specifically, Violet needs the workflow status to update to in review after a pull request is created in Bitbucket, and she can use a trigger to achieve exactly that. There’s one final thing to mention in this section workflow Properties another option to customize your workflow. A property allows you to influence actions on statuses and transitions in a workflow, such as the order of transition buttons or the resolutions displayed during a status. However, Atlas Sian recommends that you use properties at your own risk, as they may cause problems. For more information on properties, refer to the Jira Administration reference guide.