You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
When publishing an API with a backend it first tries to change the API policy and as it hasn't created the backend yet it fails because it can't find it.
Thank you for opening this issue! Please be patient while we will look into it and get back to you as this is an open source project. In the meantime make sure you take a look at the [closed issues](https://github.com/Azure/apiops/issues?q=is%3Aissue+is%3Aclosed) in case your question has already been answered. Don't forget to provide any additional information if needed (e.g. scrubbed logs, detailed feature requests,etc.).
Whenever it's feasible, please don't hesitate to send a Pull Request (PR) our way. We'd greatly appreciate it, and we'll gladly assess and incorporate your changes.
Release version
v6.0.0-alpha.1.0.8
Describe the bug
When publishing an API with a backend it first tries to change the API policy and as it hasn't created the backend yet it fails because it can't find it.
Publisher failed with error HTTP request to URI https://management.azure.com/subscriptions/***/resourceGroups/XXXXXXX/providers/Microsoft.ApiManagement/service/XXXXXXXXXX/apis/all-ecm2/policies/policy?api-version=2022-08-01 failed with status code 400. Content is '{"error":{"code":"ValidationError","message":"One or more fields contain incorrect values:","details":[{"code":"ValidationError","target":"set-backend-service","message":"Error in element 'set-backend-service' on line 33, column 4: Backend with id 'idbackEnd' could not be found."}]}}'.
Expected behavior
Backends should be created first before changing APIS policies.
Actual behavior
The backend is not created before trying to update the policies.
Reproduction Steps
Create a Backend, associate it with an API, export everything and publish it in another APIM.
The text was updated successfully, but these errors were encountered: