Notify watchers about comments restricted to groups the app account is not in

Description

Background

Shares with Display comments with restrictions enabled show restricted comments, because the share reads Jira as the share creator. Notifications do not work that way. Jira sends the comment event only when the app account can see the comment, and the listener also fetches the comment as the app account.

The app account only belongs to the product's default groups (assigned at install). Atlassian does not allow adding it to other groups, in the UI or via the API (UserModificationNotAllowed).

As a result, a comment restricted to a customer's own group shows on the share but never triggers a notification. This has been the case since before the Forge migration (see ESFJ-1902). Confirmed on QA in ESFJ-2628.

Goal

Watchers get a notification for every comment the share shows them, and only for those comments.

Linked work items

relates to
Work Item Type Icon ESFJ-2628 Restricted comments do not trigger notifications to issue watchers Priority: Medium Assignee:
Withdrawn
Work Item Type Icon ESFJ-1902 Restricted comment might trigger notification to external issue watcher Priority: Medium Assignee:
Released
Work Item Type Icon SUP-2400 Comments with restrictions are being sent via email Priority: Lowest Assignee:
Closed