Skip to content

Update ExecuteSingleResourceQueryAsync references to include parameter names#729

Merged
JonathanCrd merged 5 commits intomicrosoft:mainfrom
JonathanCrd:fix-query-regressions
Oct 7, 2025
Merged

Update ExecuteSingleResourceQueryAsync references to include parameter names#729
JonathanCrd merged 5 commits intomicrosoft:mainfrom
JonathanCrd:fix-query-regressions

Conversation

@JonathanCrd
Copy link
Copy Markdown
Member

@JonathanCrd JonathanCrd commented Oct 7, 2025

What does this PR do?

This PR fixes a problem for EventHubs and ACR where the additionalFilter value was being passed as tableName after this last parameter was introduced in PR #607.

I explicitly specified all parameter names as well, to prevent these references from breaking in the future if new parameters are added.

GitHub issue number?

Fixes #727

Pre-merge Checklist

  • Required for All PRs
    • Read contribution guidelines
    • PR title clearly describes the change
    • Commit history is clean with descriptive messages (cleanup guide)
    • Added comprehensive tests for new/modified functionality
    • Updated servers/Azure.Mcp.Server/CHANGELOG.md and/or servers/Fabric.Mcp.Server/CHANGELOG.md for product changes (features, bug fixes, UI/UX, updated dependencies)
  • For MCP tool changes:
    • One tool per PR: This PR adds or modifies only one MCP tool for faster review cycles
    • Updated servers/Azure.Mcp.Server/README.md and/or servers/Fabric.Mcp.Server/README.md documentation
    • Updated command list in /servers/Azure.Mcp.Server/docs/azmcp-commands.md and/or /docs/fabric-commands.md
    • For new or modified tool descriptions, ran ToolDescriptionEvaluator and obtained a score of 0.4 or more and a top 3 ranking for all related test prompts
    • For new tools associated with Azure services or publicly available tools/APIs/products, add URL to documentation in the PR description
  • Extra steps for Azure MCP Server tool changes:
    • Updated test prompts in /servers/Azure.Mcp.Server/docs/e2eTestPrompts.md
    • 👉 For Community (non-Microsoft team member) PRs:
      • Security review: Reviewed code for security vulnerabilities, malicious code, or suspicious activities before running tests (crypto mining, spam, data exfiltration, etc.)
      • Manual tests run: added comment /azp run mcp - pullrequest - live to run Live Test Pipeline

Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

This PR fixes parameter passing issues in ExecuteSingleResourceQueryAsync method calls across multiple Azure MCP tools. The issue occurred when the additionalFilter parameter was being passed as tableName after a recent parameter was introduced, causing BadRequest errors in EventHubs and Azure Container Registry tools.

  • Added explicit parameter names to all ExecuteSingleResourceQueryAsync calls to prevent positional parameter mismatches
  • Fixed the parameter ordering issue that was causing additionalFilter values to be incorrectly passed as tableName
  • Applied the fix consistently across six Azure tool services to prevent future breakage

Reviewed Changes

Copilot reviewed 7 out of 7 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
tools/Azure.Mcp.Tools.Storage/src/Services/StorageService.cs Added explicit parameter names to ExecuteSingleResourceQueryAsync call for storage account queries
tools/Azure.Mcp.Tools.Sql/src/Services/SqlService.cs Added explicit parameter names to ExecuteSingleResourceQueryAsync call for SQL database queries
tools/Azure.Mcp.Tools.Kusto/src/Services/KustoService.cs Added explicit parameter names to ExecuteSingleResourceQueryAsync call for Kusto cluster queries
tools/Azure.Mcp.Tools.EventHubs/src/Services/EventHubsService.cs Fixed parameter order by adding explicit names to ExecuteSingleResourceQueryAsync call for EventHubs namespace queries
tools/Azure.Mcp.Tools.AppConfig/src/Services/AppConfigService.cs Added explicit parameter names to ExecuteSingleResourceQueryAsync call for App Configuration store queries
tools/Azure.Mcp.Tools.Acr/src/Services/AcrService.cs Fixed parameter order by adding explicit names to ExecuteSingleResourceQueryAsync call for ACR registry queries
servers/Azure.Mcp.Server/CHANGELOG.md Updated changelog to document the fix for BadRequest errors in ACR and EventHubs

Comment thread servers/Azure.Mcp.Server/CHANGELOG.md Outdated
@github-project-automation github-project-automation Bot moved this from Untriaged to In Progress in Azure MCP Server Oct 7, 2025
@joshfree joshfree added this to the 2025-10 milestone Oct 7, 2025
@joshfree joshfree added server-Azure.Mcp Azure.Mcp.Server tools-Core AZMCP Core functionality that all other tools build on top of labels Oct 7, 2025
@JonathanCrd JonathanCrd enabled auto-merge (squash) October 7, 2025 20:27
@JonathanCrd JonathanCrd merged commit 0091967 into microsoft:main Oct 7, 2025
29 checks passed
@github-project-automation github-project-automation Bot moved this from In Progress to Done in Azure MCP Server Oct 7, 2025
colbytimm pushed a commit to colbytimm/microsoft-mcp that referenced this pull request Dec 8, 2025
…r names (microsoft#729)

* Add additionalFilter parameter name to GetRegistry and GetNamespace methods

* Update changelog

* Specify parameters names on all references

* Add PR to changelog

* Fix typo in changelog
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

server-Azure.Mcp Azure.Mcp.Server tools-Core AZMCP Core functionality that all other tools build on top of

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

[BUG] ExecuteSingleResourceQueryAsync regression

4 participants