Repository navigation
Preserve host-provided Durable management URL query parameters - #632
Open
Naiyuan Tian (nytian) wants to merge 3 commits into
Open
Naiyuan Tian (nytian) wants to merge 3 commits into
Naiyuan Tian (nytian) wants to merge 3 commits into
Conversation
Naiyuan Tian (nytian)
requested review from
andystaples,
Varshitha Bachu (bachuv) and
Chris Gillum (cgillum)
as code owners
November 13, 2026 19:03
Co-authored-by: Copilot <[email protected]>
There was a problem hiding this comment.
🟡 Changes recommended
Replacing only the first URL-wide occurrence can alter the authority or an unrelated path prefix while leaving the instance-ID placeholder unresolved, so substitution must target only the instance-ID path segment.
1 open issue
What changed in this PR
Updates the Durable Functions Python client’s management-link handling to preserve host-provided query parameters, including management keys, while retaining host control over key exclusion.
Changes:
- Replaces origin-wide string substitution with scheme-and-authority updates.
- Limits instance-ID substitution to the first match.
- Documents key-free URL authentication and adds compatibility tests for URL preservation, payload independence, and local RPC behavior.
| File | Description |
|---|---|
tests/models/test_http_management_compatibility.py |
Adds regression coverage for keyed and key-free URLs, response payloads, and RPC calls. |
azure/durable_functions/models/DurableOrchestrationClient.py |
Updates origin rewriting and placeholder substitution; documents key-free authentication. |
azure/durable_functions/models/DurableOrchestrationBindings.py |
Documents host ownership of URL query parameters and management-key inclusion. |
Review effort: Balanced
Comment on lines
239
to
+240
| payload[key] = payload[key].replace( | ||
| self._orchestration_bindings.management_urls["id"], instance_id) | ||
| self._orchestration_bindings.management_urls["id"], instance_id, 1) |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Summary
Key exclusion is controlled only by the extension's
httpSettings.excludeManagementKeyFromUrlsoption, which defaults tofalse. No Python-specific flag is introduced. Existing response shapes and authentication behavior are preserved; callers using key-free HTTP URLs must supply an independently obtained key throughx-functions-key.Validation
Related: Azure/azure-functions-durable-extension#3600