Repository navigation
Description
Split from #5457.
Problem: The fix adds a warning record for each failed in-process MCP tool call. Operators must see these records in Loki, with the tool label and the class, to count failures. Why deferred: This check needs the merged fix on a deployed service and a real failed MCP tool call. It cannot run offline in the pull request that changes the dispatcher. Acceptance criteria: - A Loki query over the deployment shows at least one warning record from a failed in-process MCP tool call. - The record holds the tool label and the exception class. - The record does not hold the exception message. - The issue records the query and its time range.
Proposed design
Problem statement
Operators cannot count failed in-process MCP tool calls until the warning records of #5457 reach Loki. This item documents the LogQL query on the operator page and records one live check after the merge.
Acceptance criteria
Requirement: Operator page holds the query
docs/CLUSTER.md SHALL hold a LogQL query that selects the service_name="devops-mcp-server" stream and the warning level for failed in-process MCP tool calls.
Scenario: Docs row accepts the changed page
- WHEN The branch runs
uv run devops ci --check --only docs. - THEN The docs row of Static Analysis passes with exit code 0.
Requirement: Live check returns a warning record
The recorded LogQL query MUST return at least one warning record from a failed in-process MCP tool call after the merge.
Scenario: Pending a person after the merge
- WHEN After the merge, an operator runs the recorded query in Grafana Explore after a failed in-process MCP tool call.
- THEN The query returns at least one warning record for that failed call.
Requirement: Record holds the tool label and the class
Each returned warning record MUST hold the tool label and the exception class.
Scenario: Pending a person after the merge
- WHEN After the merge, an operator opens one returned warning record in Grafana Explore.
- THEN The record holds the tool label and the exception class.
Requirement: Record omits the exception message
A returned warning record MUST NOT hold the exception message.
Scenario: Pending a person after the merge
- WHEN After the merge, an operator opens one returned warning record in Grafana Explore.
- THEN The record holds no exception message text.
Requirement: Issue records the query and the range
The issue MUST hold the query, its time range and the observed record, so a later operator can repeat the check.
Scenario: Pending a person after the merge
- WHEN After the merge, the operator finishes the live check.
- THEN The issue holds the query, the time range and the observed record.
Existing Tool Considered
No alternatives check has run on this item. Grafana Loki, queried in Grafana Explore, is the open, maintained log store and query interface that covers the need. This item builds no code. Loki covers the LogQL query and the view of a record's line and metadata. Loki lacks the record itself: the fix of #5457 writes it, and only a real failed in-process MCP tool call produces it.
Key questions
- Which deployed process writes the warning record of a failed in-process MCP tool call?: The
devops-mcp-serverDeployment runs the in-process dispatcher. Its pod sends OTLP log records to Loki under the service namedevops-mcp-server. [sources: k8s/devops/mcp-server/deployment.yaml, src/devops_cli/ai/mcp/dispatcher.py, docs/CLUSTER.md] - Where does the item document the LogQL query so an operator can repeat it?: docs/CLUSTER.md. It is the hand-written operator page for the deployed pods. It already sends a person to Grafana Explore for a query. (best practice) [sources: docs/CLUSTER.md]
- Chosen: docs/CLUSTER.md. It is the hand-written operator page. It already names Grafana Explore.
- Rejected: The issue only. An operator who looks for the query later needs a page, not a closed issue.
- Which client runs the LogQL query?: Grafana Explore on the
lokidata source. The operator page already sends a person there. Explore shows the line of a record and its metadata. (best practice) [sources: docs/CLUSTER.md]- Chosen: Grafana Explore. The operator page already sends a person to Grafana Explore. Explore shows the line and metadata of a record.
- Rejected: curl on
/loki/api/v1/query_range. The operator must build the URL and encode the query. The issue records a query, not a request.
- How does the query find a failed in-process MCP tool call?: The query selects the
service_name="devops-mcp-server"stream and the warning level thatdiscover_log_levelsfills. It filters the record by the tool label that fix(mcp): in-process tool errors return the masked message #5457 adds. The operator writes the final query into the issue at the live check, so the exact filter follows the merged record. (best practice) [sources: k8s/devops/mcp-server/deployment.yaml, src/devops_cli/grafana/service_dashboard.py, docs/CLUSTER.md]- Chosen: Stream selector, warning level and tool label. The MCP server pod writes the record under this stream. The dashboards already filter the level that
discover_log_levelsfills. - Rejected: A fixed line filter written before fix(mcp): in-process tool errors return the masked message #5457 merges. The fix is not merged. A line filter written now can name text that the fix does not write.
- Rejected: The namespace and pod labels of the container log path. That path holds the text of the container log. The OTLP log stream holds the record that the dashboards select.
- Rejected: The text of the exception message. The record holds no exception message, so the query cannot match it.
- Chosen: Stream selector, warning level and tool label. The MCP server pod writes the record under this stream. The dashboards already filter the level that
Fit
Fits in one pull request.
Suspected block
A real failed in-process MCP tool call on the deployed devops-mcp-server pod after #5457 merges and deploys.
Dependencies
Watched files
A commit on the default branch that changes one of these files starts the next refine round.
k8s/devops/mcp-server/deployment.yamlsrc/devops_cli/ai/mcp/dispatcher.py
Activity
devops-cli-service commentedon Nov 18, 2026
Both concern in-process MCP tool error handling, but #5457 delivers the code fix and the candidate delivers a post-deployment Loki verification of that fix.devops-cli-service commentedon Nov 19, 2026
Refine cannot set this item to Ready at 6ff83d4 while the items below stay open. The next refine round looks at the item again when they close, or when a person replies in a comment or edits the body.
devops-cli-service commentedon Nov 27, 2026
Next step: the open items close, or a person replies in a comment or edits the body. See Dependencies and Watched files in the section Proposed design of the body.
devops-cli-service commentedon Nov 29, 2026
Owner question: See Suspected block and Watched files in the section Proposed design of the body.
Options
Recommendation: Decide the question: only a person can answer it.
Evidence