Repository navigation
Add Microsoft.Cdn 2026-09-01-preview API version - #46300
Jay (HandsomeJay) wants to merge 45 commits into
Conversation
Next Steps to MergeNext steps that must be taken to merge this PR:
Comment generated by summarize-checks workflow run. |
|
Azure Pipelines: Successfully started running 6 pipeline(s). 3 pipeline(s) were filtered out due to trigger conditions. Some pipeline(s) encountered errors during trigger evaluation. |
API Change CheckAPIView identified API level changes in this PR and created the following API reviews
Comment generated by After APIView workflow run. |
Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com>
Adds the ErrorPolicy proxy resource under a profile, and the route-level association that applies a policy to a set of error response status codes. An error policy carries how AzureFrontDoor treats an origin's error responses. The status codes that trigger a policy live on the route association rather than on the policy itself, so a single policy can be reused by routes that fail with different status codes. Negative caching is expressed by the presence of the negativeCachingConfiguration object; there is deliberately no separate boolean switch. cacheTtlInSeconds is required for Override and SetIfMissing, and must be omitted for HonorOrigin, which defers to the origin's own caching headers. This mirrors the contract merged into the CDN resource provider, which pins both the ErrorPolicy resource and the route association to 2026-09-01-preview.
Matches the casing used by every other Microsoft.Cdn profile child resource type in this spec, and the value the RP actually returns.
|
Hi @Jay (@HandsomeJay). Your PR has had no activity for 14 days and is marked as stale. If no further updates are made within 14 days, this PR will automatically be closed. To keep this PR active, please leave a comment as the PR author or remove the |
The errorPolicies delete returns 202 and tracks completion through azure-asyncoperation rather than a Location header, matching afdEndpoints and originGroups. afdEndpoints already carries the same suppression in this tag; this was the only new LintDiff error introduced by the PR.
ErrorPolicyAssociation now derives from ResourceReference in the RP, so the referenced policy is addressed by the inherited id rather than a nested errorPolicyReference object. That keeps the route's error policy list the same wire shape as its other reference lists (customDomains, ruleSets). Dropping the nested object also makes id the array's natural identifier, so the empty x-ms-identifiers override is no longer needed and errorPolicies now emits identically to customDomains.
Reword the ErrorPolicy resource description to describe the resource itself rather than how routes consume it, and move the route-specific detail onto the new Route errorPolicies property where it belongs. Spell the service name as "Azure Front Door" in the descriptions and suppression justifications added by this change.
"Required" on its own reads as the OpenAPI required list, which the property is deliberately absent from. Say a numeric value is required instead.
…eview Add CDN AuthPolicy to 2026-09-01-preview
Contributor readiness: required accessWarning Access issues can block approvals, Azure DevOps pipelines, or labeling.
Internal contributors: set up / renew access. Recheck: Non-blocking check; fix access issues to unblock affected actions. Last updated: 2026-10-18T05:41:09.949Z |
TypeSpec suppressions requiring reviewStatus: ✅ Approved — 4 suppressions This PR adds or updates the TypeSpec suppressions listed below. Suppressions are strongly discouraged — they bypass linter rules that protect API quality and consistency. Authors should avoid adding new suppressions and prefer fixing the underlying issue; reviewers should approve only when there is a clear, compelling justification and no reasonable alternative. Review each linked rule and source location, then apply New suppressions (4)
For an overview of TypeSpec linting rules click here. 💬 Have feedback on the TypeSpec suppression flow? Let us know. |
The where-scoped form never matched: of the 13 suppressions under the package-preview-2026-09 tag, the only codes still reported as violations were the two LroLocationHeader entries, which are also the only ones carrying a where clause. The pre-existing afdEndpoints suppression uses the identical JSONPath and is equally ineffective - its violation is tolerated only because it predates this PR. Drop the where clause so the suppression matches the bare form that demonstrably works in the same block. Scope is unchanged in practice: afdEndpoints and originGroups already emit this violation identically.
…1-preview Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…ponse-2026-09-01-preview Add ClientResponse invocation point for CDN edge actions (2026-09-01-preview)
Addresses the ARM API review findings on the errorPolicies LRO contract. All three were correct: the spec described behaviour the resource provider does not implement. - PUT/PATCH 202 no longer declare an ErrorPolicy body. The RP returns RpResult<ErrorPolicy>.Accepted(location, azureAsyncOperation, retryAfter), whose three-argument overload sets the content to null, so the controller emits a bodiless 202. The resource is not in its final state at that point; clients poll the returned headers instead. - DELETE 202 now advertises the Location header that the RP already sends via ToLocationHeaderUrl. This matches routes, ruleSets, secrets, securityPolicies and AFD customDomains, which all return the same header set. - PUT 202 now advertises Retry-After, which the RP also already sends. Because the DELETE violation is fixed at the source, the lro-location-header TypeSpec suppression and the matching LintDiff suppression in readme.md are no longer needed and have been removed; readme.md is back to its original state. The two no-response-body suppressions are likewise obsolete. The remaining arm-*-operation-response-codes suppressions stay, since the RP genuinely returns 202 for these operations. delete keeps final-state-via azure-async-operation, consistent with the other Azure Front Door resources; adding the Location header would otherwise have flipped it to location. Examples updated to drop the 202 bodies accordingly.
Add error policies to Microsoft.Cdn 2026-09-01-preview
|
The suppressions have the following service-specific justifications:
|
|
[EXISTING] 🔴 Blocking [RPC-Patch-V1-10] models.tsp — line 3429 — Mergeable PATCH schemas retain defaults and required fields. Issue: At least fifteen default/required-field sites remain across the six inherited PATCH contracts—Routes, AFDCustomDomains, Endpoints, AFDOrigins, Rules, and SecurityPolicies—without counting constraints inside atomically replaced array elements. Route PATCH has a default on the supportedProtocols array property itself, as well as defaults for forwardingProtocol, linkToDefaultDomain, and httpsRedirect; recursively mergeable TLS settings require certificateType. Emitted primary anchor: Classification reasoning: The same models and violations are unchanged from Suggested fix: Introduce version-scoped PATCH-only shapes with optional mergeable fields and no defaults, preserving the existing creation models and all older API versions. For the current route PATCH shape: forwardingProtocol?: ForwardingProtocol;
linkToDefaultDomain?: LinkToDefaultDomain;
httpsRedirect?: HttpsRedirect;Remove the current-version PATCH supportedProtocols array-property default as well. Keep the scoped PatchBodyParametersSchema suppression until regenerated output passes validation; remove it only after the violating emitted shapes are fixed. |
Ravi Eda (ravimeda)
left a comment
There was a problem hiding this comment.
ARM API Review
Posting findings from the ARM API Reviewer agent (critic-verified, 2 iteration(s), converged) against commit cf828ab. See inline comments for findings 6, 10, 11, and 12. Finding 1 concerns a line unchanged in this PR's diff and is posted as a top-level PR comment rather than inline.
Approval labels observed: none.
| "api-version": "2026-09-01-preview", | ||
| "dateTimeBegin": "2020-11-04T06:49:27.554Z", | ||
| "dateTimeEnd": "2020-11-04T09:49:27.554Z", | ||
| "maxRanking": "5", |
There was a problem hiding this comment.
[EXISTING] 🟠 Warning [EX-PAYLOAD] LogAnalytics_GetLogAnalyticsRankings.json — line 6 — Ranking examples use a string for an integer parameter.
Issue: Both LogAnalytics_GetLogAnalyticsRankings.json and LogAnalytics_GetWafLogAnalyticsRankings.json use "maxRanking": "5", while the operation parameter is integer/int32 (openapi.json — line 5712 and line 6087). This is a typed-example inconsistency, not evidence that HTTP query serialization differs. JSON path: $.parameters.maxRanking.
Classification reasoning: Both prior-version source examples have the same string at line 6, and the integer parameter contract is unchanged.
Suggested fix: Update both source examples and regenerate their emitted copies:
"maxRanking": 5There was a problem hiding this comment.
All warning concern inherited examples from previous API versions and were not introduced by the new API surface in this PR. Given the current 2026-09-01-preview release plan, we will track these example corrections and address them together in the next API version.
| "tags": {} | ||
| }, | ||
| "headers": { | ||
| "azure-asyncoperation": "https://management.azure.com/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/resourceGroupName/providers/Microsoft.Cdn/operationresults/operationId?api-version=2026-09-01-preview" |
There was a problem hiding this comment.
[EXISTING] 🟠 Warning [EX-LRO-HEADERS] AFDEndpoints_Create.json — line 70 — Twenty-seven examples retain noncanonical polling-header casing.
Issue: The key azure-asyncoperation differs from the declared Azure-AsyncOperation spelling. The same lowercase key remains in 27 referenced source examples. HTTP header matching is case-insensitive; this is documentation/example consistency, not a runtime polling failure. Primary JSON path: $.responses['202'].headers['azure-asyncoperation'].
Classification reasoning: All 27 corresponding preceding-version examples contain the same lowercase key, including the cited example at line 70.
Suggested fix: Rename those source-example keys to Azure-AsyncOperation and regenerate, preserving their current URLs and operation-specific header families.
There was a problem hiding this comment.
All warning concern inherited examples from previous API versions and were not introduced by the new API surface in this PR. Given the current 2026-09-01-preview release plan, we will track these example corrections and address them together in the next API version.
| "body": { | ||
| "name": "endpoint1", | ||
| "type": "Microsoft.Cdn/profiles/afdendpoints", | ||
| "id": "/subscriptions/00000000-0000-0000-0000-000000000000/resourcegroups/RG/providers/Microsoft.Cdn/profiles/profile1/afdendpoints/endpoint1", |
There was a problem hiding this comment.
[EXISTING] 🟠 Warning [EX-RESOURCE-ID] AFDEndpoints_Create.json — line 23 — Resource IDs retain noncanonical resource-group segment casing.
Issue: Referenced examples contain 135 response resource IDs across 73 files using /resourcegroups/ instead of /resourceGroups/. This excludes legitimate tenant-scoped EdgeNodes IDs. Azure's case-insensitive matching does not make these canonical documentation examples; this is not a claim of runtime rejection. Primary JSON path: $.responses['200'].body.id.
Classification reasoning: All 73 corresponding prior-version examples contain this casing, including the cited AFDEndpoints_Create response.
Suggested fix: Replace /resourcegroups/ with /resourceGroups/ in those source response IDs and regenerate emitted copies, preserving resource names and request-consistent identifiers.
There was a problem hiding this comment.
All warning concern inherited examples from previous API versions and were not introduced by the new API surface in this PR. Given the current 2026-09-01-preview release plan, we will track these example corrections and address them together in the next API version.
| "httpsPort": 443, | ||
| "originGroupName": "origingroup1", | ||
| "originHostHeader": "www.contoso.com", | ||
| "priority": null, |
There was a problem hiding this comment.
[EXISTING] 🟠 Warning [Section 6 — Null Values] AFDOrigins_CreateWithIncomingHostHeaderValidation.json — line 37 — Origin examples return null for non-nullable optional properties.
Issue: The 200, 201, and 202 response bodies set priority, sharedPrivateLinkResource, and weight to null (lines 37/39/40, 59/61/62, and 81/83/84). The priority and weight schemas are non-nullable integers, and sharedPrivateLinkResource is a non-nullable object reference. Primary JSON path: $.responses['200'].body.properties.priority. This is a published-example defect, not evidence that the deployed service returns these values.
Classification reasoning: The same prior-version source example contains these null values at the same lines; the current emitted copy is identical to the source.
Suggested fix: Omit priority, weight, and sharedPrivateLinkResource when unset in all three source response bodies, then regenerate the emitted example. Do not invent numeric values or change the service schema to accommodate the example.
There was a problem hiding this comment.
All warning concern inherited examples from previous API versions and were not introduced by the new API surface in this PR. Given the current 2026-09-01-preview release plan, we will track these example corrections and address them together in the next API version.
Thanks for identifying this. These PATCH findings are inherited from existing resource types and are not introduced by AuthPolicy. The new AuthPolicy resource intentionally follows the existing RP behavior for this version. To support the Ignite public preview, we plan to address the contract alignment across all affected resource types in the next API version rather than changing AuthPolicy in isolation. Could you please approve the current suppressions for 2026-09-01-preview ? |
ARM (Control Plane) API Specification Update Pull Request
Tip
Overwhelmed by all this guidance? See the
Getting helpsection at the bottom of this PR description.PR review workflow diagram
Please understand this diagram before proceeding. It explains how to get your PR approved & merged.
Purpose of this PR
What's the purpose of this PR? Check the specific option that applies. This is mandatory!
Due diligence checklist
To merge this PR, you must go through the following checklist and confirm you understood
and followed the instructions by checking all the boxes:
ARM resource provider contract and
REST guidelines (estimated time: 4 hours).
I understand this is required before I can proceed to the diagram Step 2, "ARM API changes review", for this PR.
Additional information
Viewing API changes
For convenient view of the API changes made by this PR, refer to the URLs provided in the table
in the
Generated ApiViewcomment added to this PR. You can use ApiView to show API versions diff.Suppressing failures
If one or multiple validation error/warning suppression(s) is detected in your PR, please follow the
suppressions guide to get approval.
Getting help
Purpose of this PRandDue diligence checklist.write accessper aka.ms/azsdk/access#request-access-to-rest-api-or-sdk-repositoriesNext Steps to Mergecomment. It will appear within few minutes of submitting this PR and will continue to be up-to-date with current PR state.and https://aka.ms/ci-fix.
queuedstate, please add a comment with contents/azp run.This should result in a new comment denoting a
PR validation pipelinehas started and the checks should be updated after few minutes.