Skip to content

fix(ai): name each prewarm server by host and port - #2737

Merged
dan-petty merged 5 commits into
mainfrom
fix/2676-prewarm-output-server-labels
Oct 30, 2026
Merged

dan-petty merged 5 commits into
mainfrom
fix/2676-prewarm-output-server-labels

Conversation

@dan-petty

Copy link
Copy Markdown
Owner

devops ai prewarm, devops ai preload and the MCP tool ai_prewarm now name each Ollama server as host[:port]. Before, they showed the URL text of ai.ollama_urls, with its user name and query value. The nodes of the JSON and YAML output use the same names as keys. The rule is the one of #1110 and #2481: a reply names a server by host and port, never by a configured URL. The change uses server_label of #2481 and adds no URL parser.

The label model of devops_cli_ai_prewarms_total is now cut to 128 characters, and each character outside A-Za-z0-9._:/- becomes _. The calling model sets this text through the MCP tool.

Decisions:

  • The label keeps : and /, which the issue did not list. Real Ollama model names hold them (gemma4:26b, hf.co/org/repo:Q4_K_M). Without them gemma4:26b would turn into gemma4_26b.
  • The issue says a URL with no port shows as example.net:80. server_label drops the default port of the scheme, as the benchmarks do (fix(ai): the benchmarks name each server by host and port, never by a configured URL with its password #2481), so that URL shows as example.net.
  • Two URLs with one host and port (for example http://example.com and https://example.com) show as one node. The node is ok only when both URLs are ok. A reader cannot tell which scheme failed. A failure never hides.
  • The label bounds the length and the characters of a value. It does not bound the number of values.

Change: openspec/changes/archive/2026-10-30-2676-prewarm-output-server-labels/

Closes #2676

@dan-petty

Copy link
Copy Markdown
Owner Author

Test results:

  • uv run devops ci test tests/test_ai_prewarm.py tests/test_ai_cmd.py tests/test_telemetry_instruments.py: 108 passed (after the rebase on main).
  • tests/test_mcp.py and tests/test_ai_client_security.py: 182 passed.
  • uv run devops openspec check: passed.

Fail-to-pass (uv run devops ci fail-to-pass --base origin/main): 9 tests failed on base, 28 passed. The 9 failed tests:

  • test_the_tool_reply_shows_no_url_text[table] and [json]
  • test_the_json_nodes_are_keyed_by_host_and_port
  • test_the_preload_command_shows_no_url_text
  • test_two_urls_of_one_server_make_one_node_that_holds_a_failure[one failed] and [both ok]
  • test_the_label_is_bounded[symbols], [control characters] and [long]

@dan-petty dan-petty added scope/security Security linters (trivy, bandit, gitleaks, kubeconform) and Vault type/security Type security: a vulnerability or a leak labels Oct 30, 2026
@dan-petty
dan-petty marked this pull request as ready for review October 30, 2026 01:39
@dan-petty
dan-petty merged commit 2e2e4fa into main Oct 30, 2026
18 checks passed
@dan-petty
dan-petty deleted the fix/2676-prewarm-output-server-labels branch October 30, 2026 01:39
dan-petty pushed a commit that referenced this pull request Oct 30, 2026
🤖 I have created a release *beep* *boop*
---


##
[0.21.4](v0.21.3...v0.21.4)
(2026-10-30)


### Bug Fixes

* **ai:** name each prewarm server by host and port
([#2737](#2737))
([2e2e4fa](2e2e4fa)),
closes [#2676](#2676)
* **ai:** the mcp benchmark tool takes no file path
([#2738](#2738))
([5d5da15](5d5da15)),
closes [#2704](#2704)
* **config:** redact a removed credential in the config copies
([#2734](#2734))
([f663344](f663344)),
closes [#2645](#2645)
* **rag:** name the Qdrant server by host and port
([#2733](#2733))
([39aca9d](39aca9d)),
closes [#2709](#2709)
* **roadmap:** tick turn and kept diff for implement steps
([#2744](#2744))
([890d2a6](890d2a6)),
closes [#2721](#2721)
* **security:** refuse the gh and kubectl keys that run a program
([#2732](#2732))
([ad0bdf1](ad0bdf1)),
closes [#2672](#2672)
* **security:** refuse the keys that make a child write a file
([#2746](#2746))
([1cd187e](1cd187e)),
closes [#2674](#2674)

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

Co-authored-by: dan-petty-release[bot] <346998822+dan-petty-release[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

scope/security Security linters (trivy, bandit, gitleaks, kubeconform) and Vault type/security Type security: a vulnerability or a leak

Projects

None yet

Development

Successfully merging this pull request may close these issues.

fix(ai): the prewarm output names each Ollama server by its configured URL

1 participant