db_common: &db_common
  methods:
    - probe_db
  opts:
    connection_string: dbname=gitlabhq_production user=gitlab host=/var/opt/gitlab/postgresql port=5432 password=

# Web server config
server:
  listen_address: localhost
  listen_port: 9168
  name: webrick

# Probes config
probes:
  # We can group multiple probes under a single endpoint by setting the `multiple` key to `true`, followed
  # by probe definitions as usual.
  database:
    multiple: true
    ci_builds:
      class_name: Database::CiBuildsProber
      <<: *db_common
    tuple_stats:
      class_name: Database::TuplesProber
      <<: *db_common
    rows_count:
      class_name: Database::RowCountProber
      <<: *db_common
  database_bloat:
    class_name: Database::BloatProber
    <<: *db_common

  ruby: &ruby
    methods:
      - probe_gc
    opts:
      quantiles: false

  sidekiq: &sidekiq
    methods:
      - probe_stats
      - probe_queues
      - probe_workers
      - probe_retries
    opts:
      redis_url: "unix:/var/opt/gitlab/redis/redis.socket"
      redis_enable_client: true


  metrics:
    multiple: true
    ruby:
      <<: *ruby
    sidekiq:
      <<: *sidekiq


    ci_builds:
      class_name: Database::CiBuildsProber
      <<: *db_common
    tuple_stats:
      class_name: Database::TuplesProber
      <<: *db_common
    rows_count:
      class_name: Database::RowCountProber
      <<: *db_common
