Your issue involves both post-function configuration and JQL filter alignment. Here’s the complete solution:
Post-function configuration for linked issue creation:
Update your ‘Create linked issue’ post-function on the defect’s Resolve transition with the correct link type and direction. The configuration should be:
Create linked issue:
Issue type: Change Request
Link type: causes (not 'relates to' or 'is caused by')
Summary: Change Request for ${issue.key} - ${issue.summary}
Project: [your CAB project]
Initial Status: Pending CAB
The key is using ‘causes’ from the defect’s perspective - this creates a directional link where the defect ‘causes’ the CR, which is equivalent to the CR being ‘caused by’ the defect. Also set the initial status to ‘Pending CAB’ so new CRs immediately appear in your dashboard without manual status updates.
Issue link type alignment across projects:
Verify your link type configuration is consistent across projects. Go to Admin > Issues > Issue Linking > check that the ‘Cause-Effect’ link type exists and has the correct inward/outward descriptions: outward=‘causes’, inward=‘is caused by’. If your projects use different link type names, standardize them or adjust your JQL filters to accommodate variations.
CAB and release note filters using linkedIssuesOf:
Correct your CAB dashboard JQL filter to:
type = "Change Request"
AND status = "Pending CAB"
AND issueFunction in linkedIssuesOf(
"type = Defect AND severity = High",
"causes"
)
Note the link type is ‘causes’ (not ‘is caused by’) because linkedIssuesOf looks from the defect’s perspective. This finds CRs that high-severity defects ‘cause’. For release notes, use a similar filter but change the status condition to capture approved CRs: status IN ("Approved", "Implemented").
Maintaining defect-to-change traceability:
For the 40 existing CRs with incorrect ‘relates to’ links, use the Jira REST API to bulk-update link types. Create a script (or use ScriptRunner) that:
- Queries CRs: `type = “Change Request” AND issueFunction in linkedIssuesOf(“type = Defect AND severity = High”, “relates to”)
- For each CR, identifies linked defects
- Deletes the ‘relates to’ link
- Creates a new ‘causes’ link from the defect to the CR
Alternatively, if you have fewer than 50 CRs, manually update them: open each CR, remove the ‘relates to’ link, navigate to the linked defect, add a new ‘causes’ link to the CR. This is tedious but ensures accuracy.
Going forward, add a validator to your defect workflow that prevents resolution of high-severity defects unless a linked CR with ‘causes’ link type exists. This enforces the traceability requirement at the workflow level.