Skip to content

refactor(roadmap): put every decision point on one registry #5275

Open

Description

@dan-petty

Problem or Motivation

ADR 0020 puts each decision point on one registry, with one counter (devops_cli_decision_point_total), one decision record and one outcome record. Its migration steps 3, 4 and 5 move intake.proposal, implement.extension and stage_ready.completeness onto the registry and remove the old setting and the old metric of each. Today only stage.verify_screen is on the registry (src/devops_cli/roadmap/decision_registry.py: Registry((VERIFY_SCREEN,))). #4395 is closed as completed, but the move of intake (step 3) has not started.

Point Setting today Counter today Live mode
intake.proposal roadmap.intake.jev devops_cli_roadmap_intake_jev_fields_total shadow
implement.extension constants CONST_ROADMAP_IMPLEMENT_EXTENSION_* devops_cli_roadmap_implement_extension_total always on (a rule)
stage_ready.completeness roadmap.stage.jev_completeness (false) devops_cli_roadmap_jev_completeness_total off

So each point has its own record format and report, and the join of ADR 0020 section 6 covers one point only.

devops_cli_roadmap_implement_extension_total has no series in Prometheus in 21 days. _count (src/devops_cli/roadmap/implement/implement_limits.py:140-143) writes both series at each decision, so one decision makes a series. Either the rule never ran, or the metrics of the implement Job do not get to Prometheus. We do not know which.

Proposed Solution & Architectural Design

  1. Find why the extension counter has no series: look in Loki for the extension messages of the implement Job, and check that the Job exports its metrics. Fix the cause at its source, or file it when it is outside this item.
  2. Register implement.extension (rule, fallback) on the shared counter, in mode on. Remove devops_cli_roadmap_implement_extension_total.
  3. Register intake.proposal (rule: the type prefix of the title; model; fallback). Move roadmap.intake.jev into roadmap.decisions. Write the decision record, and an outcome record with the final labels when the item closes. Remove the old setting and devops_cli_roadmap_intake_jev_fields_total, with no shim. State the ConfigMap change and its order: the live ConfigMap changes before the image rolls.
  4. Register stage_ready.completeness (model, fallback) in mode off. Remove roadmap.stage.jev_completeness and its counter.

ADR 0020 says that each migration step is its own item and its own pull request. Refine can split this item into one item for each point. The registry then holds 38 series (8 + 14 + 8 + 8), under the bound of 60.

Jev beside the rule of implement.extension is not in this item. #5239 and #4847 design it.

Target Subsystem

SDLC, Git & PR Governance (src/devops_cli/roadmap/: the decision registry, intake, implement, stage_ready).

Existing Tool Considered

The project's DecisionPoint, ResolverChain and Registry (ADR 0020). No new tool. Cost: about 1.2M tokens and 1.5 days for the three moves.

Acceptance Criteria

  1. REGISTRY holds stage.verify_screen, intake.proposal, implement.extension and stage_ready.completeness. POINT_CUTS holds a cuts file for each point that has a model resolver.
  2. A test: the settings refuse the old keys roadmap.intake.jev and roadmap.stage.jev_completeness.
  3. A test: intake in shadow writes one decision record for each candidate in the format of ADR 0020 section 6, and join with an outcome record gives a fit case.
  4. A test: an implement step at its budget writes one decision with resolver="rule" and adds one count to devops_cli_decision_point_total{point="implement.extension"}.
  5. The pull request gives the cause of the missing extension series, with the Loki or Prometheus query that shows it.

Dependencies

None.

Related

Source: https://github.com/dan-petty/devops-cli/blob/main/docs/adr/0020-a-decision-point-is-a-unit-of-a-workflow-with-a-resolver-chain-and-a-rule-goes-before-a-decision-model.md

Alternatives check of 2026-11-16: not-applicable.
Class: refactor, no search.
Tool: none found.

Proposed design

Problem statement

Split the work into one item for each of the three decision points, because ADR 0020 makes each migration step its own pull request. Only stage.verify_screen is on the shared registry today. The change must register implement.extension, intake.proposal and stage_ready.completeness, remove their old settings and counters, and first explain why the extension counter has no Prometheus series.

Acceptance criteria

Requirement: Registry holds all decision points

decision_registry.REGISTRY SHALL hold stage.verify_screen, intake.proposal, implement.extension and stage_ready.completeness.

Scenario: Registry names the four points

  • WHEN A test reads REGISTRY.names.
  • THEN The set of names equals the four point names.

Requirement: Cuts files cover model points

POINT_CUTS SHALL hold a cuts file for each registered point that has a model resolver.

Scenario: Cuts table matches the registry

  • WHEN A test compares POINT_CUTS with the cuts of each point in REGISTRY.
  • THEN Each point with a model resolver has its cuts path and the mapping matches.

Requirement: Old settings are refused

The settings loader MUST refuse roadmap.intake.jev and roadmap.stage.jev_completeness.

Scenario: Old settings keys fail validation

  • WHEN A test loads settings with either old key.
  • THEN The loader raises a validation error.

Requirement: Intake proposal is registered in shadow

intake.proposal SHALL be registered in mode shadow with a rule resolver, a model resolver and a fallback resolver.

Scenario: Intake mode is shadow

  • WHEN A test reads the mode and resolvers of intake.proposal.
  • THEN The mode is shadow and the resolvers include the rule, model and fallback.

Requirement: Intake shadow writes a decision record

Intake in shadow mode SHALL write one decision record for each candidate in the format of ADR 0020 section 6 and add one count to devops_cli_decision_point_total{point="intake.proposal"}.

Scenario: Shadow intake record joins an outcome

  • WHEN A test runs intake in shadow with a candidate and an outcome record.
  • THEN The decision record joins the outcome record as a fit case and the shared counter gains one.

Requirement: Implement extension is registered on

implement.extension SHALL be registered in mode on with a rule resolver and a fallback resolver.

Scenario: Extension mode is on

  • WHEN A test reads the mode and resolvers of implement.extension.
  • THEN The mode is on and the resolvers include the rule and fallback.

Requirement: Implement budget uses the shared counter

An implement step at its budget SHALL write one decision with resolver="rule" and add one count to devops_cli_decision_point_total{point="implement.extension"}.

Scenario: Budget decision increments the shared counter

  • WHEN A test drives an implement step to its budget.
  • THEN The decision has resolver="rule" and the shared counter gains one.

Requirement: Completeness is registered off

stage_ready.completeness SHALL be registered in mode off with a model resolver and a fallback resolver.

Scenario: Completeness mode is off

  • WHEN A test reads the mode and resolvers of stage_ready.completeness.
  • THEN The mode is off and the resolvers include the model and fallback.

Requirement: Old metrics are removed

The intake, implement and stage_ready modules MUST NOT emit devops_cli_roadmap_intake_jev_fields_total, devops_cli_roadmap_implement_extension_total or devops_cli_roadmap_jev_completeness_total.

Scenario: Old metric names are absent

  • WHEN A test drives each migrated decision point and captures emitted metrics.
  • THEN No sample has any of the three old metric names.

Existing Tool Considered

The alternatives check of 2026-11-16 is not-applicable for a refactor, and it found no tool. No external open, maintained tool covers this need. The project uses its own DecisionPoint, ResolverChain and Registry from ADR 0020. The written cost is about 1.2M tokens and 1.5 days for the three moves.

Key questions

  • Should this item stay one pull request or split into one item for each decision point?: Split into one item for each point: implement.extension, intake.proposal and stage_ready.completeness. ADR 0020 says each migration step is its own item and its own pull request. (best practice) [sources: docs/adr/0020-a-decision-point-is-a-unit-of-a-workflow-with-a-resolver-chain-and-a-rule-goes-before-a-decision-model.md]
    • Chosen: One item per point. ADR 0020 requires each migration step to have its own item and pull request.
    • Rejected: One item for all three points. This breaks the ADR 0020 rule and makes the pull request too large.
  • How should the change handle the missing devops_cli_roadmap_implement_extension_total series?: Check Loki for the extension messages of the implement Job and check that the Job exports its metrics before the old metric is removed. Fix the cause at its source, or file it when the cause is outside the item. (best practice) [sources: src/devops_cli/roadmap/implement/implement_limits.py:140-143]
    • Chosen: Check Loki and metrics export before removal. _count writes both series at each decision, so one decision makes a series. Either the rule did not run or the Job metrics do not reach Prometheus.
    • Rejected: Remove the old metric without a check. This can hide a metrics export defect and let the shared counter fail in the same way.
    • Rejected: File the cause as a separate item now. The body allows a separate filing only when the cause is outside this item.
  • Which settings move into roadmap.decisions?: roadmap.intake.jev becomes the mode of intake.proposal. roadmap.stage.jev_completeness becomes the mode of stage_ready.completeness. The old keys are removed with no shim. (best practice) [sources: docs/adr/0020-a-decision-point-is-a-unit-of-a-workflow-with-a-resolver-chain-and-a-rule-goes-before-a-decision-model.md, src/devops_cli/roadmap/decision_table.py:25]
    • Chosen: Move both settings into roadmap.decisions. ADR 0020 puts each point's mode in roadmap.decisions and removes the old setting.
    • Rejected: Keep the old settings as aliases. The body requires no shim.
  • In what order do the live ConfigMap and the image change?: Change the live ConfigMap before the image rolls. The new image then reads the new roadmap.decisions keys when it starts. (best practice) [sources: docs/adr/0020-a-decision-point-is-a-unit-of-a-workflow-with-a-resolver-chain-and-a-rule-goes-before-a-decision-model.md]
    • Chosen: ConfigMap before image. The new image reads the new keys at start, so the keys must exist first.
    • Rejected: Image before ConfigMap. The new image would start with missing keys.

Fit

Needs splitting into 3 items:

  1. refactor(roadmap): register implement.extension on the decision registry
  2. refactor(roadmap): register intake.proposal on the decision registry
  3. refactor(roadmap): register stage_ready.completeness on the decision registry

Suspected block

None.

Dependencies

None.

Activity

  1. added
    source/agent
    type/refactor
    scope/roadmap
    status/new
    value/medium
    effort/medium
    on Nov 12, 2026
  2. dan-petty commented on Nov 12, 2026

    @dan-petty
    OwnerAuthor
  3. added
    priority/p2-medium
    on Nov 12, 2026
  4. devops-cli-service commented on Nov 16, 2026

    @devops-cli-service
    Contributor

    Alternatives check: not-applicable

    Class: refactor. The check makes no search and no model call for an item of this class.

    Tool: none found

    Checked on 2026-11-16. A person decides what this means for the item. The check changes no label and closes no issue.

  5. devops-cli-service commented on Nov 17, 2026

    @devops-cli-service
    Contributor

    The proposal at 551a0c3 needs splitting into 3 items. A person splits the item into the items below, or replies in a comment or edits the body to keep one item, and the next refine round looks at the item again.

    1. refactor(roadmap): register implement.extension on the decision registry
    2. refactor(roadmap): register intake.proposal on the decision registry
    3. refactor(roadmap): register stage_ready.completeness on the decision registry
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/roadmapsource/agentstatus/newtype/refactorvalue/medium

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions