Skip to content

fix(k8s): name the Loki deployment mode Monolithic #2441

Closed

Description

@dan-petty

Problem Description

k8s/logging/loki-values.yaml sets deploymentMode: SingleBinary. In the grafana-community/loki chart, SingleBinary is the deprecated name of Monolithic since chart 12.0.0. The values.schema.json of chart 20.0.2 says "Monolithic (deprecated: SingleBinary)", and the Loki upgrade guide "Upgrade from the Loki Helm chart to the Community Helm chart" (section "11.x to 12.0") tells users to change the value. The chart still accepts the old name, so the render does not change today.

The chart also renders ServiceAccount loki-memcached, because memcached.enabled is true by default. chunksCache and resultsCache are off, so no memcached pod uses that ServiceAccount.

The change for #1632 moved Loki to grafana-community/loki 20.0.2. It did not change these keys, because a parallel change edits the same values file.

Reproduction Steps

  1. Run helm template loki grafana-community/loki --version 20.0.2 -n logging -f k8s/logging/loki-values.yaml.
  2. The output holds kind: ServiceAccount with name: loki-memcached.
  3. Read deploymentMode in the chart's values.schema.json: SingleBinary is a deprecated name.

Expected vs Actual Behavior

  • Expected: the values use the current name Monolithic, and the render holds no object that nothing uses.
  • Actual: the values use the deprecated name, and the render holds an unused ServiceAccount.

Proposed change

  • Set deploymentMode: Monolithic and change the comment above read, write and backend to the new name.
  • Make _loki_mode in tests/test_k8s_local_path_placement.py accept Monolithic only.
  • Set memcached.enabled: false, and confirm with helm template that the only change in the render is the removed ServiceAccount.

Source: #1632

Proposed design

Problem statement

The Loki Helm values file uses the deprecated name SingleBinary for the deployment mode. The grafana-community/loki chart renamed it to Monolithic in version 12.0.0. The values file also renders an unused ServiceAccount loki-memcached because memcached.enabled defaults to true, while chunksCache and resultsCache are both off. This change sets the current name and removes the unused ServiceAccount.

Acceptance criteria

Requirement: deploymentMode uses the current name

The values file SHALL set deploymentMode to Monolithic.

Scenario: values file holds the current name

  • WHEN k8s/logging/loki-values.yaml is read
  • THEN deploymentMode is Monolithic and no line holds SingleBinary as a value

Requirement: comments use the current name

Every comment in the values file that names the deployment mode SHALL use Monolithic.

Scenario: no comment holds the old name

  • WHEN k8s/logging/loki-values.yaml is read
  • THEN no comment line contains the word SingleBinary

Requirement: memcached is disabled

The values file SHALL set memcached.enabled to false.

Scenario: memcached key is present and false

  • WHEN k8s/logging/loki-values.yaml is read
  • THEN memcached.enabled is false

Requirement: render holds no unused ServiceAccount

The helm template output SHALL contain no ServiceAccount named loki-memcached.

Scenario: render has no loki-memcached

  • WHEN helm template loki grafana-community/loki --version 20.0.2 -n logging -f k8s/logging/loki-values.yaml is run
  • THEN the output holds no document with kind ServiceAccount and name loki-memcached

Requirement: test accepts only Monolithic

The function _loki_mode SHALL accept Monolithic and reject SingleBinary.

Scenario: test fails on the old name

  • WHEN _loki_mode is called with a values dict whose deploymentMode is SingleBinary
  • THEN the function raises pytest.fail

Existing Tool Considered

No check has run. The change edits values for the existing grafana-community/loki Helm chart, which already supports Monolithic as the deployment mode and memcached.enabled: false. No new tool or library is needed. The written cost is editing two files (k8s/logging/loki-values.yaml and tests/test_k8s_local_path_placement.py) and verifying with helm template.

Key questions

  • What is the current name of the deployment mode in grafana-community/loki chart 20.0.2?: Monolithic. The chart's values.schema.json says Monolithic (deprecated: SingleBinary), and the upgrade guide for 11.x to 12.0 tells users to change the value. [sources: openspec/changes/archive/2026-10-28-1632-loki-grafana-community-chart/design.md:46, k8s/logging/loki-values.yaml:6]
  • Should _loki_mode accept only Monolithic or both Monolithic and SingleBinary?: Only Monolithic. The body's proposed change says to make _loki_mode accept Monolithic only. The project should use the current name and not keep the deprecated alias. (best practice) [sources: openspec/changes/archive/2026-10-28-1632-loki-grafana-community-chart/design.md:54, tests/test_k8s_local_path_placement.py:62]
    • Chosen: Accept only Monolithic. The body's proposed change states this. The project should use the current name and drop the deprecated alias so a future chart that removes SingleBinary does not break the test.
    • Rejected: Accept both Monolithic and SingleBinary. The chart still accepts the old name for backward compatibility. However, the project controls its own values file and should not depend on a deprecated alias.
  • Does disabling memcached.enabled remove any other rendered resource?: No. chunksCache and resultsCache are both false, so no pod uses the memcached ServiceAccount. The only rendered resource removed is the ServiceAccount loki-memcached. [sources: k8s/logging/loki-values.yaml:94, k8s/logging/loki-values.yaml:97]

Fit

Fits in one pull request.

Suspected block

None.

Dependencies

None.

Activity

  1. added
    source/agent
    type/bug
    status/new
    value/low
    effort/low
    on Oct 28, 2026
  2. dan-petty commented on Oct 28, 2026

    @dan-petty
    OwnerAuthor

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

  3. added
    priority/p3-low
    on Oct 28, 2026
  4. added
    scope/k8s
    on Oct 30, 2026
  5. added
    status/ready
    and removed
    status/new
    on Oct 30, 2026
  6. devops-cli-service commented on Oct 30, 2026

    @devops-cli-service
    Contributor

    Status set to Ready at c6a837d (see proposed design in issue body).

  7. devops-cli-service commented on Nov 2, 2026

    @devops-cli-service
    Contributor

    Staged: branch fix/2441-loki-values-name-the-monolithic-deployment, draft pull request #3278. The pull request plans the item and closes no issue.

    The task groups, with the tokens of the inputs of each step, for a budget of 40000 tokens:

    1. Name the current Loki deployment mode in the values and turn memcached off: 10003 tokens
    2. Make the Loki claim test accept Monolithic only: 10664 tokens
    3. Write the change folder and archive it: 6000 tokens

    The plan run made 2 model request(s), and used 104669 input tokens and 5718 output tokens. The tool calls, in order:

    1. read_file({"path":"tests/core/test_k8s_local_path_placement.py","start_line":1,"end_line":140})
    2. references({"name":"SingleBinary"})
    3. read_spec({"capability":"loki-release-pin"})
    4. list_files({"directory":"k8s/logging"})

    A model review of the plan found these points. They stop no draft, and a person judges them:

    • criterion_dropped at groups, criteria: The issue requires that helm template renders no loki-memcached ServiceAccount and that the render changes in no other way. No group runs helm template. The feasibility lists the command as a check only, and the spec scenarios only read the values file. Evidence: "Set memcached.enabled: false, and confirm with helm template that the only change in the render is the removed ServiceAccount."
    • verify_form at group 1: The verify command does not check the work of group 1. The test accepts both Monolithic and SingleBinary before the change, and it never reads memcached.enabled. It passes with or without the edit. Evidence: "uv run devops ci test tests/core/test_k8s_local_path_placement.py"
  8. added 2 commits that reference this issue on Nov 3, 2026
  9. 9 remaining items

  10. devops-cli-service commented on Nov 3, 2026

    @devops-cli-service
    Contributor

    The runner Job devops-cli-runner-20261103-100320-094d ended: succeeded.
    Image digest: sha256:ef0d0ace3359daaf57e2bb1904dd131a16eca5fd52c54ffdcfeb5cf25f2c41f8

    The last lines of its log:

    Tool call: shell, program git, ok.
    Tool call: shell, started: other
    Tool call: shell, program other, refused.
    Tool call: shell, started: uv run python -c <masked>
    Tool call: shell, program uv, refused.
    Tool call: shell, started: uv run python -c <masked>
    Tool call: shell, program uv, refused.
    Tool call: shell, started: uv run devops ci test tests/core/test_k8s_local_path_placement.py
    Tool call: shell, program uv, ok.
    Tool call: shell, started: other
    Tool call: shell, program other, refused.
    Tool call: shell, started: uv run devops ci test tests/commands/k8s/test_k8s.py
    Tool call: shell, program uv, ok.
    Tool call: shell, started: grep -r SingleBinary k8s/logging/loki-values.yaml
    Tool call: shell, program grep, ok.
    Tool call: shell, started: other
    Tool call: shell, program other, refused.
    Tool call: shell, started: git diff --name-only
    Tool call: shell, program git, ok.
    Tool call: shell, started: git diff k8s/logging/loki-values.yaml | grep -v ...
    Tool call: shell, program git, refused.
    Tool call: read_file, ok.
    Tool call: read_file, ok.
    Tool call: shell, started: grep -n memcached: k8s/logging/loki-values.yaml
    Tool call: shell, program grep, ok.
    Tool call: shell, started: other
    Tool call: shell, program other, refused.
    Tool call: shell, started: grep -n SingleBinary k8s/logging/loki-values.yaml tests/commands/k8s/test_k8s.py tests/core/test_k8s_local_path_placement.py
    Tool call: shell, program grep, ok.
    Tool call: shell, started: uv run devops ci test tests/core/test_k8s_local_path_placement.py
    Tool call: shell, program uv, ok.
    Tool call: shell, started: other
    Tool call: shell, program other, refused.
    Tool call: edit_file, ok.
    Tool call: shell, started: other
    Tool call: shell, program other, refused.
    Restored the tasks.md of the change 2441-loki-values-name-the-monolithic-deployment. A step only ticks the tasks of its own group.
    Failure class refused_tool. Action left: wait.
    ✓ Took 0 item(s) to a ready pull request, stopped 1.
    Elapsed: 5m 33s
    
  11. added
    status/planned
    and removed
    owner/service
    status/blocked
    on Nov 3, 2026
  12. devops-cli-service commented on Nov 3, 2026

    @devops-cli-service
    Contributor

    Cleared the stop at group 1 by the rule digest: the runner image changed since the stop, from sha256:ef0d0ace3359daaf57e2bb1904dd131a16eca5fd52c54ffdcfeb5cf25f2c41f8 to sha256:71484cc064d6ab241bf53e6464dad843cc76f71025f0e46dc59adee51ae9b14f. The item is Planned again, and the Service takes it in the next round. The Service clears a stop one time for each runner image. A new stop on this image waits for a comment implement: retry.

  13. added
    status/in-progress
    status/in-review
    and removed
    status/planned
    status/in-progress
    on Nov 6, 2026
  14. changed the title [-]fix(k8s): loki values name the monolithic deployment mode and render no unused memcached service account[/-] [+]fix(k8s): name the Loki deployment mode Monolithic[/+] on Nov 6, 2026
  15. dan-petty commented on Nov 6, 2026

    @dan-petty
    OwnerAuthor

    The job shortened the title of this item. The summary had 94 characters, and the limit is 60. The type and the scope stay.

  16. removed
    status/in-review
    on Nov 6, 2026
  17. devops-cli-service commented on Nov 6, 2026

    @devops-cli-service
    Contributor

    Live since 2026-11-06 16:15 UTC

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/lowpriority/p3-lowscope/k8ssource/agenttype/bugvalue/low

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions