Allow Filtering by subscribed issues in the graphql api
What does this MR do?
This MR allows a user to filter issues to only the subscribed issues within the graphql api. Subscribed Issues are issues where you are receiving email notifications and where the toggle on the bottom right of the right sidebar is on.
This offers an API-based solution to the problem in this issue: #14972
However, It only exposed exlicitly subscribed issues.
Rather than doing this to close any particular issue, I'm opening this because I would personally like to use this endpoint in my day to day work. The related issue has 300
Query plan using my user id and the gitlab-org/gitlab project with 3 years of subscriptions:
SELECT "issues".* FROM "issues" INNER JOIN "subscriptions" ON "subscriptions"."subscribable_type" = 'Issue' AND "subscriptions"."subscribable_id" = "issues"."id" WHERE "issues"."project_id" = 278964 AND "subscriptions"."user_id" = 4626651 ORDER BY "issues"."created_at" DESC, "issues"."id" DESC LIMIT 101;
https://console.postgres.ai/gitlab/gitlab-production-tunnel-pg12/sessions/15326/commands/53339
Screenshots or Screencasts (strongly suggested)
Edited by Allison Browne