Open simonmalletrc opened 2 weeks ago
Azure Functions doesn't support route prefixes for built-in HTTP APIs. There are a couple things you can consider to work around this:
I recommend the latter since it gives you the most control and flexibility.
Description
First off, in local development everything is working fine. Now, we deploy our durable function in a container using AKS. We use ingress rules to route traffic from dev-services.site.com/wam/data-syncer-api/ to the specific container hosting the durable function. the ingress rules has a rewrite path
I also add that prefix to environment variable DFM_INGRESS_ROUTE_PREFIX = wam/data-syncer-api
Once deployed, the durable function is accessible properly but we are having trouble using the built-in http endpoints for orchestrators.
For example,
https://dev-services.site.com/wam/data-syncer-api/orchestrators/myapp/42
returnsAs you can see the route prefix wam/data-syncer-api is not present in the orchestrator urls. If I try to manually ADD the prefix and call the route to view all instances
https://dev-services.site.com/wam/data-syncer-api/runtime/webhooks/durabletask/instances?code=longcodehere
How can we make the durable function orchestrator built-in http endpoints work if we have a route prefix?
Expected behavior
The following URL should show me the list of all running instances knowing that wam/data-syncer-api is a route prefix to the container
https://dev-services.site.com/wam/data-syncer-api/runtime/webhooks/durabletask/instances?code=longcodehere
Actual behavior
an error appears
Relevant source code snippets
Known workarounds
Create a custom endpoint to display the status and ignore the built-in endpoints...
App Details
Screenshots
If deployed to Azure