Skip to content

Commit

Permalink
Fix network SDK issue Azure#34094 (Azure#34227)
Browse files Browse the repository at this point in the history
* initial attempt

* mitigate the breaking change

* resolve comments

* update changelog
  • Loading branch information
ArcturusZhang authored Feb 22, 2023
1 parent 37979dd commit f892638
Show file tree
Hide file tree
Showing 6 changed files with 50 additions and 7 deletions.
2 changes: 2 additions & 0 deletions sdk/network/Azure.ResourceManager.Network/CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@

### Bugs Fixed

- Fixed issue https://github.com/Azure/azure-sdk-for-net/issues/34094. Please use `EffectiveNetworkSecurityGroup.TagToIPAddresses` instead of `EffectiveNetworkSecurityGroup.TagMap`.

### Other Changes

## 1.1.1 (2023-02-13)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6319,7 +6319,10 @@ internal EffectiveNetworkSecurityGroup() { }
public Azure.ResourceManager.Network.Models.EffectiveNetworkSecurityGroupAssociation Association { get { throw null; } }
public System.Collections.Generic.IReadOnlyList<Azure.ResourceManager.Network.Models.EffectiveNetworkSecurityRule> EffectiveSecurityRules { get { throw null; } }
public Azure.Core.ResourceIdentifier NetworkSecurityGroupId { get { throw null; } }
[System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Never)]
[System.ObsoleteAttribute("This property is obsolete and might be removed in a future version, please use `TagToIPAddresses` instead", false)]
public string TagMap { get { throw null; } }
public System.Collections.Generic.IReadOnlyDictionary<string, System.Collections.Generic.IList<string>> TagToIPAddresses { get { throw null; } }
}
public partial class EffectiveNetworkSecurityGroupAssociation
{
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
// Copyright (c) Microsoft Corporation. All rights reserved.
// Licensed under the MIT License.

#nullable disable

using System;
using System.ComponentModel;

namespace Azure.ResourceManager.Network.Models
{
public partial class EffectiveNetworkSecurityGroup
{
/// <summary> Mapping of tags to list of IP Addresses included within the tag. </summary>
[EditorBrowsable(EditorBrowsableState.Never)]
[Obsolete("This property is obsolete and might be removed in a future version, please use `TagToIPAddresses` instead", false)]
public string TagMap { get; }
}
}

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 4 additions & 0 deletions sdk/network/Azure.ResourceManager.Network/src/autorest.md
Original file line number Diff line number Diff line change
Expand Up @@ -100,6 +100,7 @@ rename-mapping:
EndpointType: ConnectionMonitorEndpointType
ConnectionState: NetworkConnectionState
ApplicationGatewayAvailableSslOptions: ApplicationGatewayAvailableSslOptionsInfo
EffectiveNetworkSecurityGroup.tagMap: tagToIPAddresses

format-by-name-rules:
'tenantId': 'uuid'
Expand Down Expand Up @@ -382,6 +383,9 @@ directive:
transform: >
$.ResourceNavigationLinkFormat.properties.link['x-ms-format'] = 'arm-id';
$.ServiceAssociationLinkPropertiesFormat.properties.link['x-ms-format'] = 'arm-id';
- from: networkInterface.json # a temporary fix for issue https://github.com/Azure/azure-sdk-for-net/issues/34094
where: $.definitions.EffectiveNetworkSecurityGroup.properties.tagMap.type
transform: return "object";
```
### Tag: package-track2-preview
Expand Down

0 comments on commit f892638

Please sign in to comment.