Skip to content

fix(service): the ConfigMap carries github_requests_per_hour and the high-request alert follows the limit #2755

Description

@dan-petty

Problem or Motivation

The owner raised the Service's GitHub request budget from 500 to 2000 requests an hour on 2026-10-30. The change cannot be made through the project's own tools:

  1. k8s/configmap.py (_service_block) copies only repos, github_app, drain_timeout_seconds and poll_interval_seconds from the active settings into ConfigMap devops-cli-config. service.github_requests_per_hour is not copied, so every devops k8s deploy-stack --stack devops renders a ConfigMap without it, and the Service falls back to the default of 500.
  2. The field ServiceConfig.github_requests_per_hour has no Variable() marker and no description, so no environment variable names it and devops config show does not list it.
  3. The alert RoadmapServiceGitHubRequestsHigh in k8s/monitoring/prometheus-values.yaml fires above 450 requests in an hour, which is 90 percent of the default budget. With a budget of 2000 it fires for a normal hour.

The live ConfigMap now holds github_requests_per_hour: 2000, patched by hand on 2026-10-30. The next deploy-stack renders the template again and removes it.

Proposed Solution & Architectural Design

  • _service_block copies github_requests_per_hour like drain_timeout_seconds and poll_interval_seconds. The ConfigMap renders it when the active settings give it.
  • The field gets a Variable() marker and a description, so it appears in devops config show, docs/ENV_VARS.md and docs/CONFIGURATION.md.
  • The alert compares the sent requests with the limit that the Service reports (devops_cli_service_budget_limit_requests): more than 90 percent of the limit in an hour. The rule text and k8s/README.md say so, and a promtool test covers a limit of 500 and a limit of 2000.

Target Subsystem

src/devops_cli/k8s/configmap.py, src/devops_cli/config/settings.py, k8s/monitoring/prometheus-values.yaml, tests/fixtures/prometheus_rules/.

Existing Tool Considered

The existing ConfigMap renderer and the metric devops_cli_service_budget_limit_requests that the Service already exports. promtool for the rule test (already pinned). Nothing new is built.

Acceptance criteria

  • With the active settings at 2000, the rendered ConfigMap holds github_requests_per_hour: 2000. With the default, it holds none.
  • DEVOPS_CLI_SERVICE_GITHUB_REQUESTS_PER_HOUR sets the field, and the generated documents list it.
  • The alert fires at more than 90 percent of the reported limit: it stays quiet at 900 sent requests for a limit of 2000, and fires at 1900.
  • uv run devops ci passes, and devops docs generate --sync-readme is run.

Activity

  1. added
    source/agent
    type/bug
    scope/service
    status/new
    value/medium
    effort/medium
    on Oct 30, 2026
  2. dan-petty commented on Oct 30, 2026

    @dan-petty
    OwnerAuthor

    Intake placed this item to the backlog: intake puts every new item in the backlog. A person plans the milestones.

    • Type: type/bug. The fix prefix of the title gives the type.
    • Scope: scope/service. The (service) scope of the title gives the scope.
    • Priority: P2-Medium. The next deploy-stack removes the hand-patched ConfigMap value and the alert fires at a wrong threshold, but the Service still runs.
    • Value: Medium. It restores correct config propagation and stops false alerts at the raised budget, which matters for daily operations.
    • Effort: Medium. Three source files change, plus a promtool test and a docs sync, but no new tool is built.
    • Related: fix(monitoring): the roadmap Service alerts count the first value of a new series and see a lane of a new pod #2505, which asks for a different change. Both modify the RoadmapServiceGitHubRequestsHigh rule in prometheus-values.yaml, but 2505 fixes the increase() first-value gap while the candidate changes the threshold to follow the reported limit.
  3. added
    priority/p2-medium
    status/in-progress
    status/in-review
    and removed
    status/new
    status/in-progress
    on Oct 30, 2026
  4. added a commit that references this issue on Oct 30, 2026
    809d85b
  5. removed
    status/in-review
    on Oct 30, 2026
  6. added a commit that references this issue on Oct 30, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    effort/mediumpriority/p2-mediumscope/servicesource/agenttype/bugvalue/medium

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions