mvisonneau / gitlab-ci-pipelines-exporter

Prometheus / OpenMetrics exporter for GitLab CI pipelines insights
Apache License 2.0
1.21k stars 239 forks source link

Missing job metrics (enabled in config) #790

Open tony-engineering opened 4 months ago

tony-engineering commented 4 months ago

Hi, I tried to setup the exporter using Helm, and I am missing metrics for jobs. I searched in the issues here and saw similar issues without clear solution. I checked in my config that I enabled the export of jobs metrics, but that didnt help. When I go to Prometrheus UI, and search for "gitlabci", I can only see "gitlab_ci_pipelines". I would expect to see "gitlab_cijob..." image

Here is my config

config:
  gitlab:
    url: https://gitlab.com
    # You can also configure the token using --gitlab-token
    # or the  environment variable
    token: <token>
  wildcards:
  - {}
  projects:
    - name: org/mint
  project_defaults:
    output_sparse_status_metrics: true
    pull:
      environments:
        enabled: false
        regexp: ".*"
        exclude_stopped: true
      refs:
        branches:
          enabled: true
          regexp: "^main|master$"
          most_recent: 0
          max_age_seconds: 0
          exclude_deleted: true
        tags:
          enabled: true
          regexp: ".*"
          most_recent: 0
          max_age_seconds: 0
          exclude_deleted: true
        merge_requests:
          enabled: false
          most_recent: 0
          max_age_seconds: 0
      pipeline:
        jobs:
          enabled: true
          from_child_pipelines:
            enabled: false
          runner_description:
            enabled: true
            aggregation_regexp: shared-runners-manager-(\d*)\.gitlab\.com
        variables:
          enabled: false
          regexp: ".*"

Can you help me here ? Thanks

tony-engineering commented 4 months ago

Somehow some additional metrics showed up after I uninstall / reinstall the chart multiple times ... I tried to rollback and the metrics are still shown, weird

sebglon commented 3 months ago

I have the same. No Job metrics are generated here is my config:

      project_defaults:
        refs:
          regexp: ".*"
        pull:
          refs:
            tags:
              enabled: false
            merge_requests:
              enabled: true
              max_age_seconds: 10800 # 3h
        pipeline:
          jobs:
            enabled: true
            runner_description:
              enabled: false
      wildcards:
        - owner:
            name: ubbleai
            kind: group
          pull:
            refs:
              tags:
                enabled: false
              merge_requests:
                enabled: true
                max_age_seconds: 10800 # 3h
            pipeline:
              jobs:
                enabled: true
                runner_description:
                  enabled: false
kingindanord commented 1 month ago

same here