MCP Tools in Drills: Drill Add or Update Resources - #3371
Conversation
|
Azure Pipelines: Successfully started running 1 pipeline(s). There may be pipelines that require an authorized user to comment /azp run to run. |
There was a problem hiding this comment.
Pull request overview
Adds a new Azure Resilience Management drill command that can add, update, or exclude drill target resources, wiring it through the toolset service layer and surfacing it through the Azure MCP Server’s tool catalog and docs.
Changes:
- Introduces
resilience_drill_resource_add-or-updatecommand + options/model and registers it in the ResilienceManagement toolset. - Implements the backing service operation (
AddOrUpdateDrillResourcesAsync) and AOT JSON context registrations. - Updates Azure MCP Server discovery surfaces (consolidated tools, command docs, e2e prompts) and adds unit + recorded integration coverage.
Reviewed changes
Copilot reviewed 14 out of 14 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| tools/Azure.Mcp.Tools.ResilienceManagement/tests/Azure.Mcp.Tools.ResilienceManagement.Tests/ResilienceManagementCommandTests.cs | Adds recorded/live integration coverage for the new drill add-or-update flow. |
| tools/Azure.Mcp.Tools.ResilienceManagement/tests/Azure.Mcp.Tools.ResilienceManagement.Tests/Drills/Resources/DrillAddOrUpdateResourcesCommandTests.cs | Adds unit tests for validation, success path, and error sanitization. |
| tools/Azure.Mcp.Tools.ResilienceManagement/tests/Azure.Mcp.Tools.ResilienceManagement.Tests/assets.json | Updates the recorded test assets tag for the toolset. |
| tools/Azure.Mcp.Tools.ResilienceManagement/src/Services/ResilienceManagementService.cs | Implements AddOrUpdateDrillResourcesAsync using the ARM SDK drill resource LRO. |
| tools/Azure.Mcp.Tools.ResilienceManagement/src/Services/IResilienceManagementService.cs | Extends the service interface for the new drill resources operation. |
| tools/Azure.Mcp.Tools.ResilienceManagement/src/ResilienceManagementSetup.cs | Registers the new command in DI and wires it into the resilience drill resource command group. |
| tools/Azure.Mcp.Tools.ResilienceManagement/src/Options/Drills/Resources/DrillAddOrUpdateResourcesOption.cs | Defines CLI/tool options for include, update, exclude, force flags, and fault duration. |
| tools/Azure.Mcp.Tools.ResilienceManagement/src/Models/DrillAddOrUpdateResourcesResult.cs | Adds a result model for operation tracking (operationId, hasCompleted). |
| tools/Azure.Mcp.Tools.ResilienceManagement/src/Commands/ResilienceManagementJsonContext.cs | Registers new response/result types for source-generated JSON serialization (AOT-safe). |
| tools/Azure.Mcp.Tools.ResilienceManagement/src/Commands/Drills/Resources/DrillAddOrUpdateResourcesCommand.cs | Adds the tool command implementation, input validation, payload shaping, and error mapping. |
| servers/Azure.Mcp.Server/src/Resources/consolidated-tools.json | Adds the new tool name so it is discoverable through consolidated tool mapping. |
| servers/Azure.Mcp.Server/docs/e2eTestPrompts.md | Adds e2e prompt coverage for the new tool. |
| servers/Azure.Mcp.Server/docs/azmcp-commands.md | Documents the new azmcp resilience drill resource add-or-update command. |
| servers/Azure.Mcp.Server/changelog-entries/dhruvbharuka-drill-add-or-update-resources.yml | Adds a changelog entry announcing the new tool. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
| [Theory] | ||
| [InlineData("--drill drill1 --fault-duration-minutes 10 --include-resources " + IncludeJson, false)] | ||
| [InlineData("--service-group sg1 --fault-duration-minutes 10 --include-resources " + IncludeJson, false)] | ||
| [InlineData("--service-group sg1 --drill drill1 --include-resources " + IncludeJson, false)] | ||
| [InlineData("--service-group sg1 --drill drill1 --fault-duration-minutes 10", false)] |
| "resilience_usageplan_enrollment_create", | ||
| "resilience_recoveryplan_create", | ||
| "resilience_recoveryplan_delete", | ||
| "resilience_recoveryplan_resource_update" | ||
| "resilience_recoveryplan_resource_update", | ||
| "resilience_drill_resource_add-or-update" |
Tool Description Evaluator ResultsTest 1Expected Tool: Results
Test 2Expected Tool: Results
|
What does this PR do?
[Provide a clear, concise description of the changes][Add additional context, screenshots, or information that helps reviewers]GitHub issue number?
[Link to the GitHub issue this PR addresses]Pre-merge Checklist
servers/Azure.Mcp.Server/README.mdand/orservers/Fabric.Mcp.Server/README.mddocumentationREADME.mdchanges running the script./eng/scripts/Process-PackageReadMe.ps1. See Package READMEToolDescriptionEvaluatorand obtained a score of0.4or more and a top 3 ranking for all related test promptsconsolidated-tools.jsonbreaking-changelabelservers/Azure.Mcp.Server/docs/azmcp-commands.md./eng/scripts/Update-AzCommandsMetadata.ps1to update tool metadata inazmcp-commands.md(required for CI)servers/Azure.Mcp.Server/docs/e2eTestPrompts.mdcrypto mining, spam, data exfiltration, etc.)/azp run mcp - pullrequest - liveto run Live Test Pipeline