Skip to content
Snippets Groups Projects

Add issue prefilling support for o11y metrics

Open Max Woolf requested to merge 2886/opstrace/prefil-metric-issues into master
1 unresolved thread

What does this MR do and why?

  • Adds support for prefilling issue titles and descriptions with metric information.

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.

Before After

How to set up and validate locally

  1. Enable feature flag observability_features

  2. Ensure you have a working Ultimate licence.

  3. Create a new group, and project within it.

  4. Create a new issue by visiting the issues/new page with the correct urlencoded payload. Here's an example:

    /new?observability_metric_details={"fullUrl"%3A"http%3A%2F%2Fgdk.test%3A3000%2Fgitlab-org%2Fgitlab-test%2F-%2Fmetrics%2Fapp.ads.ad_requests%3Ftype%3DSum%26date_range%3D1h%26group_by_fn%3Dsum%26group_by_attrs[]%3Dapp.ads.ad_request_type%26group_by_attrs[]%3Dapp.ads.ad_response_type"%2C"name"%3A"app.ads.ad_requests"%2C"type"%3A"Sum"%2C"dimensions"%3A["app.ads.ad_request_type"%2C"app.ads.ad_response_type"]%2C"timeframe"%3A["2024-07-2504%3A47%3A00UTC"%2C"2024-07-2505%3A47%3A00UTC"]%2C"latestValues"%3A["app.ads.ad_request_type%3ANOT_TARGETED%2Capp.ads.ad_response_type%3ARANDOM%3A281.000"%2C"app.ads.ad_request_type%3ATARGETED%2Capp.ads.ad_response_type%3ATARGETED%3A1387.000"%2C"app.ads.ad_request_type%3ATARGETED%2Capp.ads.ad_response_type%3ARANDOM%3A287.000"]}

    Note: This issue will add a button that generates and links that payload automatically.

  5. Ensure that the issue is prefilled with a title that looks like Issue created from app.ads.ad_requests

  6. Ensure that the issue is prefilled with the description :point_down:

    [Metric details](http://gdk.test:3000/gitlab-org/gitlab-test/-/metrics/app.ads.ad_requests?type=Sum&date_range=1h&group_by_fn=sum&group_by_attrs[]=app.ads.ad_request_type&group_by_attrs[]=app.ads.ad_response_type) \
    Name: `app.ads.ad_requests` \
    Type: `Sum` \
    Timeframe: `2024-07-2504:47:00UTC - 2024-07-2505:47:00UTC`

Relates to gitlab-org/opstrace/opstrace#2886 (closed)

Edited by Max Woolf

Merge request reports

Loading
Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
  • Daniele Rossetti
  • Max Woolf added 1 commit

    added 1 commit

    Compare with previous version

  • Max Woolf changed milestone to %17.3

    changed milestone to %17.3

  • Max Woolf changed the description

    changed the description

  • Max Woolf added 1 commit

    added 1 commit

    • df2c5828 - Change output based on review suggestions

    Compare with previous version

  • Max Woolf marked this merge request as ready

    marked this merge request as ready

  • Max Woolf changed the description

    changed the description

  • Max Woolf added 1 commit

    added 1 commit

    • e5fae43c - Change output based on review suggestions

    Compare with previous version

  • Max Woolf
  • Daniele Rossetti requested review from @drosse

    requested review from @drosse

  • Max Woolf changed the description

    changed the description

  • Max Woolf requested review from @ssuman3

    requested review from @ssuman3

  • @mwoolf LGTM from o11y point of view :smile:

  • Daniele Rossetti removed review request for @drosse

    removed review request for @drosse

  • Daniele Rossetti approved this merge request

    approved this merge request

  • added pipelinetier-2 label and removed pipelinetier-1 label

  • Before you set this MR to auto-merge

    This merge request will progress on pipeline tiers until it reaches the last tier: pipelinetier-3. We will trigger a new pipeline for each transition to a higher tier.

    Before you set this MR to auto-merge, please check the following:

    • You are the last maintainer of this merge request
    • The latest pipeline for this merge request is pipelinetier-3 (You can find which tier it is in the pipeline name)
    • This pipeline is recent enough (created in the last 8 hours)

    If all the criteria above apply, please set auto-merge for this merge request.

    See pipeline tiers and merging a merge request for more details.

  • Daniele Rossetti mentioned in merge request !161449 (merged)

    mentioned in merge request !161449 (merged)

  • E2E Test Result Summary

    allure-report-publisher generated test report!

    e2e-test-on-gdk: :white_check_mark: test report for 1fba0757

    expand test summary
    +------------------------------------------------------------------+
    |                          suites summary                          |
    +-------------+--------+--------+---------+-------+-------+--------+
    |             | passed | failed | skipped | flaky | total | result |
    +-------------+--------+--------+---------+-------+-------+--------+
    | Release     | 5      | 0      | 0       | 0     | 5     | ✅     |
    | Create      | 127    | 0      | 12      | 0     | 139   | ✅     |
    | Verify      | 44     | 0      | 2       | 0     | 46    | ✅     |
    | Plan        | 70     | 0      | 0       | 0     | 70    | ✅     |
    | Data Stores | 31     | 0      | 1       | 0     | 32    | ✅     |
    | Fulfillment | 2      | 0      | 0       | 0     | 2     | ✅     |
    | Govern      | 71     | 0      | 0       | 0     | 71    | ✅     |
    | Monitor     | 8      | 0      | 0       | 0     | 8     | ✅     |
    | Package     | 16     | 0      | 15      | 0     | 31    | ✅     |
    | Analytics   | 2      | 0      | 0       | 0     | 2     | ✅     |
    | Secure      | 2      | 0      | 0       | 0     | 2     | ✅     |
    | Manage      | 0      | 0      | 1       | 0     | 1     | ➖     |
    +-------------+--------+--------+---------+-------+-------+--------+
    | Total       | 378    | 0      | 31      | 0     | 409   | ✅     |
    +-------------+--------+--------+---------+-------+-------+--------+

    e2e-package-and-test: :white_check_mark: test report for 1fba0757

    expand test summary
    +---------------------------------------------------------------------+
    |                           suites summary                            |
    +----------------+--------+--------+---------+-------+-------+--------+
    |                | passed | failed | skipped | flaky | total | result |
    +----------------+--------+--------+---------+-------+-------+--------+
    | GitLab Metrics | 2      | 0      | 1       | 0     | 3     | ✅     |
    | Monitor        | 12     | 0      | 13      | 0     | 25    | ✅     |
    | Create         | 270    | 0      | 34      | 0     | 304   | ✅     |
    +----------------+--------+--------+---------+-------+-------+--------+
    | Total          | 284    | 0      | 48      | 0     | 332   | ✅     |
    +----------------+--------+--------+---------+-------+-------+--------+
  • Max Woolf added 1 commit

    added 1 commit

    • e49f51d5 - Change output based on review suggestions

    Compare with previous version

  • Daniele Rossetti
  • Max Woolf added 1 commit

    added 1 commit

    • faf2a9b2 - Apply 1 suggestion(s) to 1 file(s)

    Compare with previous version

  • Daniele Rossetti requested review from @drosse

    requested review from @drosse

  • Max Woolf added 1 commit

    added 1 commit

    Compare with previous version

  • Max Woolf added 1 commit

    added 1 commit

    Compare with previous version

  • Max Woolf requested review from @ssuman3

    requested review from @ssuman3

  • Daniele Rossetti
  • Surabhi Suman approved this merge request

    approved this merge request

  • Max Woolf requested review from @rutgerwessels

    requested review from @rutgerwessels

  • Max Woolf added 1 commit

    added 1 commit

    • beefb335 - Apply 1 suggestion(s) to 1 file(s)

    Compare with previous version

    • Resolved by Rutger Wessels

      @mwoolf I still believe that this 'create title/description' should live somewhere else so we have better separation of concerns. And use issue[title] and issue[description] parameters (with some ?o11y_isssue=true flag.

      I have one comment for the specs. The code itself looks good.

  • Rutger Wessels removed review request for @rutgerwessels

    removed review request for @rutgerwessels

  • Max Woolf added 1 commit

    added 1 commit

    • 4da349e5 - Refactor to move presentation out of issue service

    Compare with previous version

  • Max Woolf requested review from @rutgerwessels

    requested review from @rutgerwessels

  • Rutger Wessels approved this merge request

    approved this merge request

  • Rutger Wessels enabled automatic add to merge train when checks pass

    enabled automatic add to merge train when checks pass

  • Rutger Wessels resolved all threads

    resolved all threads

  • Max Woolf aborted automatic add to merge train because the source branch was updated. Learn more.

    aborted automatic add to merge train because the source branch was updated. Learn more.

  • Max Woolf added 1 commit

    added 1 commit

    Compare with previous version

  • Max Woolf reset approvals from @rutgerwessels by pushing to the branch

    reset approvals from @rutgerwessels by pushing to the branch

  • Rutger Wessels approved this merge request

    approved this merge request

  • Rutger Wessels resolved all threads

    resolved all threads

  • merged

  • Max Woolf mentioned in commit ec6ee0e0

    mentioned in commit ec6ee0e0

  • added workflowstaging label and removed workflowcanary label

  • Max Woolf mentioned in merge request !161619 (merged)

    mentioned in merge request !161619 (merged)

  • Max Woolf mentioned in merge request !163150 (merged)

    mentioned in merge request !163150 (merged)

  • Please register or sign in to reply
    Loading