Import issue links as dimension

Issue linking in Jira is a powerful option and is widely used. You can import issue links in eazyBI by using advanced settings for custom fields.
In this article, I will try to explain how to set up and import issue links in eazyBI. There can be several use cases on what exactly users want to track in eazyBI with issue links. To demonstrate it, I will take one simple relation: stories with linked bugs.

You can analyze this use case from two perspectives.

  • One is to track Stories and how many Bugs are linked to them;
  • And the opposite - track Bugs and how many Stories are linked to them.

Let’s start with the first situation: a user wants to see Stories with linked Bugs.

When defining the setting for linked issues, you have to keep in mind the general rule: check the link name in the issue screen you consider as a “parent” issue or, in other words, the issue from what perspective you want to analyze linked issues. In this case, if we want to get all bugs created for the story, then we have to check the link name in the story issue screen.

In the print screen above, we can see that the issue link name is “causes”. First, we have to check whether this link name is for inward or the outward endpoint of the link. Keep in mind that the link name could differ accordingly to its direction!
For that, we go to Jira administration “Issue linking” (see screenshot below).
In my example, “causes” is the outward direction:

We define additional calculated custom fields using advanced settings for custom fields. In this case, the settings to import linked bugs to stories look like this:

# Bugs linked to Stories
[jira.customfield_stories_bugs]
name = "Bugs linked to Stories"
outward_link = "causes"
multiple_values = true
dimension = true

If this link type can be used to link different issue type issues (not only bugs), then we can also limit that only linked issues with a specific issue type (“Bug”) will be imported:

# Bugs linked to Stories
[jira.customfield_stories_bugs]
name = "Bugs linked to Stories"
outward_link = "causes"
issue_type = "Bug"
multiple_values = true
dimension = true

You can define several issue types as well:

issue_type = ["Bug", "Incident"]

Not only multiple issue types can be defined, but also several outward or inward links, for example:

outward_link = ["causes", "blocks"]

In some cases, the inward and outward links are used both for the same need and endpoints even may have the same name (i.g. “relates to”), and users use both of them. Then add in the definition both directions:

outward_link = "relates to" 
inward_link = "relates to"

In eazyBI import options, we select “Bugs linked to Stories” to be imported as dimension and issue property. Here is how it looks in eazyBI based on my example from the PrintScreen - DG-173 (story) with its linked bugs.

Now let’s look at the opposite use case - get all Bugs with their linked Stories. Keep in mind the general rule, and let’s go to the Bug issue as it is the “parent” in this case.

As we can see in the PrintScreen - DG-105 (bug) above, the link name is “is caused by” what is an inward direction in my Jira:

We define additional calculated custom fields using advanced settings for custom fields. In this case, my settings look like this:

# Stories linked to Bugs
[jira.customfield_bugs_stories]
name = "Stories linked to Bugs"
inward_link = "is caused by"
multiple_values = true
dimension = true

In eazyBI import options, we select “Stories linked to Bugs” to be imported as dimension and issue property. Here is how it looks in eazyBI based on my example from the PrintScreen - DG-105 (bug) with its linked stories.

Keep in mind - whenever you change the advanced settings for a custom field or hierarchy, it is recommended to either do the full reimport of the data in the account or to clear the previously loaded custom field configuration (run the import with the custom field un-checked) and load it again (run the import with the custom field checked).

See also:

1 Like