Skip to content

MPG migration - ServiceNetworking#54422

Merged
ArthurMa1978 merged 30 commits intoAzure:mainfrom
mzhongl524:pr-service-networking-from-tsp
Jan 7, 2026
Merged

MPG migration - ServiceNetworking#54422
ArthurMa1978 merged 30 commits intoAzure:mainfrom
mzhongl524:pr-service-networking-from-tsp

Conversation

@mzhongl524
Copy link
Copy Markdown
Member

@mzhongl524 mzhongl524 commented Dec 10, 2025

Fixed: #53900
TSP PR: Azure/azure-rest-api-specs#39161

Use the new code generator to generate SDK code from TSP.

Contributing to the Azure SDK

Please see our CONTRIBUTING.md if you are not familiar with contributing to this repository or have questions.

For specific information about pull request etiquette and best practices, see this section.

@github-actions github-actions Bot added the Mgmt This issue is related to a management package. label Dec 10, 2025
@github-actions
Copy link
Copy Markdown

github-actions Bot commented Dec 23, 2025

API Change Check

APIView identified API level changes in this PR and created the following API reviews

Azure.ResourceManager.ServiceNetworking

@mzhongl524 mzhongl524 changed the title [ServiceNetworking] Verify that the new code generator generates SDK code from TSP MPG migration - ServiceNetworking Dec 24, 2025
@RodgeFu
Copy link
Copy Markdown
Member

RodgeFu commented Dec 31, 2025

seems need to re-record the test

@ArthurMa1978 ArthurMa1978 marked this pull request as ready for review January 6, 2026 06:18
@ArthurMa1978 ArthurMa1978 self-requested a review as a code owner January 6, 2026 06:18
Copilot AI review requested due to automatic review settings January 6, 2026 06:18
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR migrates the ServiceNetworking SDK from the legacy code generator to the new Management Plane Generator (MPG/TypeSpec). The migration updates the code generation configuration, fixes test code patterns, and regenerates all SDK code with the new generator.

Key changes:

  • Updated code generator configuration to use the new Azure TypeSpec HTTP client management emitter
  • Fixed async/await patterns in test code (replacing .Result with await)
  • Fixed return type of helper methods from async void to async Task
  • Added property initialization workarounds for serialization
  • Regenerated all SDK code with new generator patterns

Reviewed changes

Copilot reviewed 15 out of 135 changed files in this pull request and generated no comments.

Show a summary per file
File Description
tsp-location.yaml Updated to use new management generator emitter and updated commit hash
TrafficControllerTests.cs Fixed async patterns, added property initialization workarounds, changed method return types
TrafficControllerResource.cs Regenerated with new generator - updated patterns and structure
TrafficControllerResource.Serialization.cs Updated serialization implementation
TrafficControllerFrontendResource.cs Regenerated with new generator patterns
TrafficControllerFrontendResource.Serialization.cs Updated serialization implementation
TrafficControllerFrontendData.cs Updated data model with new property pattern
TrafficControllerFrontendData.Serialization.cs Updated serialization with new patterns
TrafficControllerFrontendCollection.cs Regenerated collection implementation
TrafficControllerData.cs Updated data model with property wrapper pattern
TrafficControllerData.Serialization.cs Updated serialization implementation
TrafficControllerCollection.cs Regenerated collection with new patterns
TrafficControllerAssociationResource.cs Regenerated with new generator patterns
TrafficControllerAssociationResource.Serialization.cs Updated serialization implementation
TrafficControllerAssociationData.cs Updated data model structure
TrafficControllerAssociationData.Serialization.cs Updated serialization patterns
ProviderConstants.cs Minor update to class modifier
WafSecurityPolicy.cs New generated model file
WafSecurityPolicy.Serialization.cs New serialization for WAF model
WafPolicy.cs New generated model file
WafPolicy.Serialization.cs New serialization for WAF model
TrafficControllerUpdateProperties.cs Updated internal data structure
CodeGenMemberAttribute.cs New internal attribute for code generation

@ArthurMa1978 ArthurMa1978 merged commit 0d5f59a into Azure:main Jan 7, 2026
21 checks passed
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 package.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

MPG migration - servicenetworking

4 participants