Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Include resource ID in OAV validation response #1047

Open
wwendyc opened this issue Oct 10, 2024 · 1 comment · Fixed by #1055
Open

Include resource ID in OAV validation response #1047

wwendyc opened this issue Oct 10, 2024 · 1 comment · Fixed by #1055
Assignees

Comments

@wwendyc
Copy link
Contributor

wwendyc commented Oct 10, 2024

In the OAV validation response, include the resource ID if it's available to make it easier for RPs to tell which resources require fixing.

Example of what's currently returned for a LIST GET in the validation error results:

{
  "isSuccessful": false,
  "operationInfo": {
    "operationId": "SqlServerInstances_List",
    "apiVersion": "2021-11-01"
  },
  "errors": [
    {
      "code": "INVALID_TYPE",
      "message": "Expected type string but found type null",
      "source": {
        "url": "specification/azurearcdata/resource-manager/Microsoft.AzureArcData/stable/2021-11-01/sqlServerInstances.json",
        "jsonRef": "#/definitions/SqlServerInstanceProperties/properties/containerResourceId",
        "position": {
          "line": 59,
          "column": 32
        }
      },
      "documentationUrl": "",
      "pathsInPayload": [
        "/value/4/properties/containerResourceId",
        "/value/5/properties/containerResourceId",
        "/value/6/properties/containerResourceId"
      ],
      "jsonPathsInPayload": [
        "$.value[4].properties.containerResourceId",
        "$.value[5].properties.containerResourceId",
        "$.value[6].properties.containerResourceId"
      ],
      "schemaPath": "#/properties/containerResourceId/type"
    }
  ]
}

REST API spec operation definition: https://github.com/Azure/azure-rest-api-specs/blob/main/specification/azurearcdata/resource-manager/Microsoft.AzureArcData/stable/2021-11-01/azurearcdata.json#L351

Example: https://github.com/Azure/azure-rest-api-specs/blob/main/specification/azurearcdata/resource-manager/Microsoft.AzureArcData/stable/2021-11-01/examples/ListSubscriptionSqlServerInstance.json#L41

@scbedd scbedd self-assigned this Oct 15, 2024
@scbedd scbedd moved this from 🤔 Triage to 🔬 Dev in PR in Azure SDK EngSys 🚢🎉 Oct 15, 2024
@scbedd scbedd moved this from 🔬 Dev in PR to 🐝 Dev in Azure SDK EngSys 🚢🎉 Oct 15, 2024
@github-project-automation github-project-automation bot moved this from 🐝 Dev to 🎊 Closed in Azure SDK EngSys 🚢🎉 Jan 8, 2025
@scbedd scbedd moved this from 🎊 Closed to 🔬 Dev in PR in Azure SDK EngSys 🚢🎉 Jan 8, 2025
@scbedd scbedd reopened this Jan 8, 2025
@github-project-automation github-project-automation bot moved this from 🔬 Dev in PR to 🤔 Triage in Azure SDK EngSys 🚢🎉 Jan 8, 2025
@scbedd
Copy link
Member

scbedd commented Jan 8, 2025

Awaiting confirmation from RPaaS team before closing the issue.

@scbedd scbedd moved this from 🤔 Triage to 📋 Backlog in Azure SDK EngSys 🚢🎉 Jan 8, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: 📋 Backlog
Development

Successfully merging a pull request may close this issue.

2 participants