Rename ManagedOps interface to ManagedOperations to avoid namespace conflict#40737
Merged
ArthurMa1978 merged 8 commits intomainfrom Feb 26, 2026
Merged
Rename ManagedOps interface to ManagedOperations to avoid namespace conflict#40737ArthurMa1978 merged 8 commits intomainfrom
ArthurMa1978 merged 8 commits intomainfrom
Conversation
…onflict The interface name ManagedOps conflicts with the C# SDK namespace Azure.ResourceManager.ManagedOps, causing the generator to use an underscore-prefixed internal namespace (_ManagedOps) as a workaround. Renaming the interface to ManagedOperations resolves this conflict. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Next Steps to MergeNext steps that must be taken to merge this PR:
Comment generated by summarize-checks workflow run. |
live1206
added a commit
to azure-sdk/azure-sdk-for-net
that referenced
this pull request
Feb 25, 2026
Points to spec PR: Azure/azure-rest-api-specs#40737 Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Revert interface name to ManagedOps to avoid swagger changes. Add @@clientName(ManagedOps, 'ManagedOperations', 'csharp') in client.tsp to rename only for the C# SDK generation. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
live1206
added a commit
to azure-sdk/azure-sdk-for-net
that referenced
this pull request
Feb 25, 2026
Spec now uses @@clientName(ManagedOps, 'ManagedOperations', 'csharp') in client.tsp instead of renaming the interface, keeping swagger unchanged. Spec PR: Azure/azure-rest-api-specs#40737 Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Replace 'alias enablementState' with 'union EnablementStatus' and 'alias desiredEnablementState' with 'union DesiredEnablementState'. This gives all language SDKs proper enum type names instead of generator-derived names like 'ChangeTrackingInformationEnablementStatus' or 'DesiredConfigurationDefenderForServers'. Also removes the #suppress directives for unnamed unions since named unions don't trigger the lint rule. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
This reverts commit 78ac12d.
Rename types to avoid name collisions: - AzureMonitorInformation -> ManagedOpsAzureMonitorInformation - ChangeTrackingInformation -> ManagedOpsChangeTrackingInformation - ProvisioningState -> ManagedOpsProvisioningState - ServiceInformation -> ManagedOpsServiceInformation - Convert enablementState alias to named union EnablementState, renamed to ManagedOpsEnablementStatus for C# Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
…ate types - DesiredConfiguration -> ManagedOpsDesiredConfiguration - DesiredConfigurationUpdate -> ManagedOpsDesiredConfigurationUpdate - desiredEnablementState alias -> named union DesiredEnablementState, renamed to ManagedOpsDesiredEnablementState for C# Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
ArthurMa1978
approved these changes
Feb 26, 2026
nandakishores
pushed a commit
to nandakishores/azure-rest-api-specs
that referenced
this pull request
Feb 26, 2026
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.
Problem
The TypeSpec \interface ManagedOps\ in \specification/managedoperations/ManagedOps.Management/managedOps.tsp\ generates an internal class named \ManagedOps\ in the .NET SDK. This conflicts with the SDK namespace \Azure.ResourceManager.ManagedOps, forcing the generator to use \Azure.ResourceManager._ManagedOps\ as a workaround.
Fix
Rename \interface ManagedOps\ to \interface ManagedOperations\ to eliminate the name conflict. This allows the .NET SDK to use the correct namespace \Azure.ResourceManager.ManagedOps.
Related SDK PR