Skip to content

mgmt, Migrate azure-resourcemanager-cdn to TypeSpec#48177

Draft
weidongxu-microsoft wants to merge 23 commits intoAzure:mainfrom
weidongxu-microsoft:migrate-cdn
Draft

mgmt, Migrate azure-resourcemanager-cdn to TypeSpec#48177
weidongxu-microsoft wants to merge 23 commits intoAzure:mainfrom
weidongxu-microsoft:migrate-cdn

Conversation

@weidongxu-microsoft
Copy link
Member

@weidongxu-microsoft weidongxu-microsoft commented Mar 2, 2026

Migrate azure-resourcemanager-cdn from autorest to TypeSpec emitter. Spec PR: Azure/azure-rest-api-specs#40902

TODO: major task to switch to AFD based profile and endpoint and rule -- letting agent write it
481ef5f

- Add implementation.models to module-info.java
- Add CDN revapi suppressions for expected breaking changes
- Regenerated SDK code from TypeSpec

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@github-actions github-actions bot added the Mgmt This issue is related to a management-plane library. label Mar 2, 2026
@weidongxu-microsoft weidongxu-microsoft force-pushed the migrate-cdn branch 2 times, most recently from e9ea4bb to bd54e70 Compare March 2, 2026 08:40
@weidongxu-microsoft weidongxu-microsoft changed the title Migrate azure-resourcemanager-cdn to TypeSpec mgmt, Migrate azure-resourcemanager-cdn to TypeSpec Mar 2, 2026
Comment on lines -19 to 24
public final class CacheExpirationActionParameters implements JsonSerializable<CacheExpirationActionParameters> {
public final class CacheExpirationActionParameters extends DeliveryRuleActionParameters {
/*
* The typeName property.
*/
private String typeName = "DeliveryRuleCacheExpirationActionParameters";
private DeliveryRuleActionParametersType typeName
= DeliveryRuleActionParametersType.DELIVERY_RULE_CACHE_EXPIRATION_ACTION_PARAMETERS;

Copy link
Member Author

@weidongxu-microsoft weidongxu-microsoft Mar 2, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Breaking changes are mostly on these classes.

However, I am a bit puzzled why it was not a polymorphic class in 2024-02-01
https://github.com/Azure/azure-rest-api-specs/blob/main/specification/cdn/resource-manager/Microsoft.Cdn/Cdn/stable/2024-02-01/cdn.json#L5245-L5256
<-- this uses "allOf DeliveryRuleActionParameters"

And this be the base
https://github.com/Azure/azure-rest-api-specs/blob/main/specification/cdn/resource-manager/Microsoft.Cdn/Cdn/stable/2024-02-01/cdn.json#L3197-L3223

Seems either m4 or emitter spread the base into it? As there is typeName property, which comes from base.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Mgmt This issue is related to a management-plane library.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants