Skip to content

Jira Issues - Only accept filtering by allowed projects

What does this MR do and why?

This change prohibits jira issues to be filtered by a project_key that is not present in configuration project_keys.

Resolves issue: #455496 (closed)

Scenarios, given we have 3 JIRA projects (TEST1, TEST2, TEST3):

  • When project_keys are configured as project_keys = TEST1,TEST2:

    The user can only filter by TEST1 and TEST2 projects (e.g., ?project=TEST1).

  • When project_keys is empty:

    It is possible to filter by all projects (TEST1, TEST2, TEST3).

MR acceptance checklist

Please evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.

Screenshots or screen recordings

Screenshots are required for UI changes, and strongly recommended for all other merge requests.

Screen_Recording_2024-04-15_at_13.20.22

How to set up and validate locally

  1. Enable Feature Flag multiple_jira_project_keys
  2. Enable jira integration for the project you want to view jira issues for
  3. In the integrations configuration form populate it with multiple jira keys(comma separated) (the keys should be valid jira keys otherwise the jira api will raise an error)
  4. Now visit the page plan -> Jira Issues (Under the project)
  5. While you are in the jira issues page add an extra param project in the url, if project param is provided it should filter the jira issues according to the param (eg <>?project=NOT_ALLOWED)
  6. It should not return the jira issues for project NOT_ALLOWED
Edited by Ivane Gkomarteli

Merge request reports