This feature can now be more easily developed, as Atlassian added a generic “parent” variable in Issue model (available in rest api, cf my screenshot).
Moreover, Atlassian is going to deprecate Epic-link and replace it with parent https://support.atlassian.com/jira-software-cloud/docs/upcoming-changes-epic-link-replaced-with-parent/
- a Sub-task has a “parent”
- a Story has a “parent” that can be an Epic or any custom hierarchy Parent
- an Epic has a “parent” that can be an Initiative, or any custom hierarchy Parent
No matter of Advanced roadmaps or other, every parenting link is now generic.
So we could have a parentOf(query) generic JQL that return immediate parents of issues returned by query, simply by returning issue.fields.parent …