This PR add a swagger validation to validate resource path names.
If there are two resource paths with the same name, one with and one without trailing slashes, it will be considered an error since those are considered as one resource in the API deployment.
With this fix, following internal REST APIs provide 400 Bad request in such cases
PUT https://localhost:9443/api/am/publisher/v4/apis/<apiId>/swagger
Response:
{
"code": 900754,
"message": "Error while parsing OpenAPI definition",
"description": "Multiple GET operations with the same resource path /menu found in the openapi definition",
"moreInfo": "",
"error": []
}
Purpose
This PR add a swagger validation to validate resource path names. If there are two resource paths with the same name, one with and one without trailing slashes, it will be considered an error since those are considered as one resource in the API deployment.
With this fix, following internal REST APIs provide 400 Bad request in such cases
PUT https://localhost:9443/api/am/publisher/v4/apis/<apiId>/swagger
Response:
This validation executes in,
Fixes