Skip to main content
Skip table of contents

Synchronization using the “relates to” link doesn't work randomly

Symptom

Let's consider a synchronization that works in one direction (unidirectional) with only one link direction, as follows:

image-20240816-132350.png

Sometimes, synchronization fails for some unknown reasons.


Cause

This problem occurs because you're using the “Relates” link type, whose two link directions have the same name (“relates to”), and it's not possible to know in which direction synchronization should take place.

There are 3 parameters that determine when a synchronization is triggered:

  • Source issues: It's a JQL that lists the issues from which synchronization will be triggered.

  • Target issues: It's a JQL that lists the issues that are linked to the source issues and in which changes will be made.

  • Link direction: The link(s) direction(s) between the source and target issues that must be taken into account for synchronization to be triggered.

When one issue is linked to another, there are two possible link directions, that are configured on the Issue Linking page:

image-20240814-160140.png

In Elements Copy & Sync, these directions are represented by arrows (→) or (←):

image-20240816-081855.png

Most of the time, link directions have different names, and it's easy to distinguish them, such as the “Blocks” link type, where:

  • is blocked by” is the inward link

  • blocks” is the outward link

But in the case of the “Relates” link type, both directions have the same name and it's not possible to distinguish them:

image-20240816-085716.png

As a result, if only one direction is set in a C&S synchronization, the sync will fail if that direction doesn't match the direction used in the Jira ticket:

image-20240816-091236.png
image-20240816-090744.png

How to find out the link direction

In the case of the “Relates” link type, the direction depends on where the link was created:

  • The inward issue is the source issue from which the link was created.

  • The outward issue is the target issue.

For example, if you go to issue A and link it to issue B, then issue A will be the inward while issue B will be the outward.

Link direction

Action

relates to (→)

synchronizes from inward to outward

relates to (←)

synchronizes from outward to inward

If you don't know which link direction is used between two tickets, you can use the Jira REST API and type the following endpoint in your browser address bar:

CODE
https://YOUR_JIRA_BASE_URL/rest/api/latest/issue/ISSUE_KEY?fields=issuelinks

You will have to replace YOUR_JIRA_BASE_URL and ISSUE_KEY according to your own Jira instance, and you will then see if the linked ticket is inward or outward:

image-20240816-092556.png

Solutions

If the C&S synchronization uses only one of the two directions:

image-20240816-090744.png

Then you need to make sure that all the issues you want to synchronize are linked in the good direction, otherwise the sync will not be triggered.

However, if this is not the case and the issues you want to synchronize are linked with both directions, then you need to add both directions to your C&S synchronization:

image-20240816-094311.png
JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.