...
What Are Contexts?
Contexts connect various configurations and settings to a Scope. The scope of a Context may be composed of:
- A project (optional)
- An Issue Type (optional)
- JQL filter (optional)
The scope determines which issues the Context is applicable for; these are displayed in the Contexts menu in an expandable list.
To create a new Context, click on the Add button:
Context Attributes
Context attributes have four main aspects:
- the scope for which the context is set (project/issue type/JQL)
- the content that is applicable to the scope
- Email This Issue notifications applicable to the scope
- additional settings within the scope
Context scope
The scope maps all the context settings to a certain project/issue type/JQL or a combination of these.
...
Defines a JQL condition to match the set of issues the context may be applied to. JQL Filter with combination of Project and Issue Type selected is used to determine if the Context is applicable to an Issue being sent in an email.
...
Content and Notifications
The content of a context specifies templates and canned responses to be used when sending manual emails.
...
Categories are groups of Email Templates that are made available in the email screen to choose from. Once selected here, users are able to choose a template from the given category on the email screen's dropdown list.
...
Note |
---|
Either a Template or a Notification is mandatory. You cannot create "empty" contexts without one of these. |
Additional Settings
Additional content settings allow you to further configure options for your outgoing emails.
...
...
Enable this if you want each recipient to receive a separate email instead of sending a single email to all recipients.
...
Select the SMTP connection to be used to deliver emails via this Context. Default is Jira's outgoing mail setting.
Status | ||||
---|---|---|---|---|
|
...
Custom Email headers of outgoing emails may be set using this attribute. The field should contain email headers in the format of headername:headervalue, multiple headers should be entered one per line. Find more details on how email headers are set in outgoing emails.
Status | ||||
---|---|---|---|---|
|
Context Resolution Algorithm
There may be multiple contexts applicable for an issue. The best-matching context is selected for each issue to determine the email template or notification rules that apply to that issue.
Contexts are resolved from the strongest to the weakest match. Here are the steps performed:
- Find all Contexts that are configured with a project and an issue type, and iterate through each of them in the order of the Order attribute (see above):
- if the Context that is being evaluated has a JQL filter, check if the Issue matches it. If so, we stop processing and use the Context.
- If the Context that is being evaluated does not have a JQL filter, we stop processing and use the Context.
- If no Context has been found in the previous step, find all Contexts that are configured with an Issue Type but not with a Project, and iterate through each of them in the order of the Order attribute (see above):
- if the Context that is being evaluated has a JQL filter, check if the Issue matches it. If so, we stop processing and use the Context.
- If the Context that is being evaluated does not have a JQL filter, we stop processing and use the Context.
- If no Context has been found in the previous step, find all Contexts that are configured with an Project but not with an Issue Type, and iterate through each of them in the order of the Order attribute (see above):
- if the Context that is being evaluated has a JQL filter, check if the Issue matches it. If so, we stop processing and use the Context.
- If the Context that is being evaluated does not have a JQL filter, we stop processing and use the Context.
- If no Context has been found in the previous step, find all Contexts that are not configured with an Issue Type or a Project, and iterate through each of them in the order of the Order attribute (see above):
- if the Context that is being evaluated has a JQL filter, check if the Issue matches it. If so, we stop processing and use the Context.
- If the Context that is being evaluated does not have a JQL filter, we stop processing and use the Context.
- If no Context has been found in the previous steps, use an implicit default Context.
Context Examples
Some examples of Contexts:
...
Some examples of contexts are evaluated for an issue:
...
Issue attributes:
- Project: Project1
- Type: Bug
- Priority: Normal
- Unresolved
...
Issue attributes:
- Project: Project1
- Type: Bug
- Priority: Normal
- Resolution: Fixed
...
Context 1 is not matching the issue as it is resolved.
Context 2 is not matching the issue as it is of Normal priority.
Context 3 is not matching the issue as it is of Normal priority.
Context 4 is matching the issue.
...
Issue attributes:
- Project: Project2
- Type: Bug
- Priority: Critical
- Resolution: Fixed
...
Context 1-4 is not matching the issue as it is in Project2 not Project 1.
Context 5 is not matching the issue as it is a Bug not a New Feature.
Context 6 is matching the issue as it is of Critical priority.
...
Issue attributes:
- Project: Project2
- Type: Task
- Priority: Minor
- Resolution: Fixed
...
Context 1-6 is not matching the issue as it is not fulfilling the Context attributes.
Context 7 is matching the issue as the Context does not have any restriction
Examples of how Contexts are resolved:
- for an issue that is a Bug in project P1, the first context is selected
- for an issue that is a Bug in some other project P2, the second context is selected
- for an issue that is an Improvement (non-Bug) in project P1, the third context is selected
- for an issue that is an Improvement (non-Bug) in some other project P2, the fourth context is selected
...
title | On this page |
---|
...
Expertisefinder redirect | ||||||||
---|---|---|---|---|---|---|---|---|
|