From fc33693d96a5775cceb76e154befda2da1d0aa26 Mon Sep 17 00:00:00 2001 From: SDKAuto Date: Mon, 7 Jun 2021 06:47:55 +0000 Subject: [PATCH] CodeGen from PR 14687 in Azure/azure-rest-api-specs Merge 757409f42a0d5f527fc91ea9e103bd568c70168c into a252633188c5e02c4071cc1c3b5cead249db8a54 --- .../src/Generated/ISqlManagementClient.cs | 10 ++++---- .../src/Generated/Models/Server.cs | 24 ++++++++++++++++++- ...rkAccess.cs => ServerNetworkAccessFlag.cs} | 4 ++-- .../src/Generated/Models/ServerUpdate.cs | 24 ++++++++++++++++++- .../Generated/SdkInfo_SqlManagementClient.cs | 13 +--------- .../src/Generated/ServersOperations.cs | 16 ++++++------- .../src/Generated/SqlManagementClient.cs | 12 +++++----- 7 files changed, 68 insertions(+), 35 deletions(-) rename sdk/sqlmanagement/Microsoft.Azure.Management.Sql/src/Generated/Models/{ServerPublicNetworkAccess.cs => ServerNetworkAccessFlag.cs} (84%) diff --git a/sdk/sqlmanagement/Microsoft.Azure.Management.Sql/src/Generated/ISqlManagementClient.cs b/sdk/sqlmanagement/Microsoft.Azure.Management.Sql/src/Generated/ISqlManagementClient.cs index 4cfc0360356ed..bc688ed524ab5 100644 --- a/sdk/sqlmanagement/Microsoft.Azure.Management.Sql/src/Generated/ISqlManagementClient.cs +++ b/sdk/sqlmanagement/Microsoft.Azure.Management.Sql/src/Generated/ISqlManagementClient.cs @@ -552,11 +552,6 @@ public partial interface ISqlManagementClient : System.IDisposable /// IServerOperations ServerOperations { get; } - /// - /// Gets the IServersOperations. - /// - IServersOperations Servers { get; } - /// /// Gets the IServerSecurityAlertPoliciesOperations. /// @@ -662,6 +657,11 @@ public partial interface ISqlManagementClient : System.IDisposable /// IRestorableDroppedManagedDatabasesOperations RestorableDroppedManagedDatabases { get; } + /// + /// Gets the IServersOperations. + /// + IServersOperations Servers { get; } + /// /// Gets the IUsagesOperations. /// diff --git a/sdk/sqlmanagement/Microsoft.Azure.Management.Sql/src/Generated/Models/Server.cs b/sdk/sqlmanagement/Microsoft.Azure.Management.Sql/src/Generated/Models/Server.cs index 8861fa95aba9f..cb46c725411ef 100644 --- a/sdk/sqlmanagement/Microsoft.Azure.Management.Sql/src/Generated/Models/Server.cs +++ b/sdk/sqlmanagement/Microsoft.Azure.Management.Sql/src/Generated/Models/Server.cs @@ -64,11 +64,17 @@ public Server() /// Possible values include: 'Connected', 'Disconnected' /// The resource id of a /// user assigned identity to be used by default. + /// The Client id used for cross tenant + /// CMK scenario /// A CMK URI of the key to use for /// encryption. /// The Azure Active Directory identity of /// the server. - public Server(string location, string id = default(string), string name = default(string), string type = default(string), IDictionary tags = default(IDictionary), ResourceIdentity identity = default(ResourceIdentity), string kind = default(string), string administratorLogin = default(string), string administratorLoginPassword = default(string), string version = default(string), string state = default(string), string fullyQualifiedDomainName = default(string), IList privateEndpointConnections = default(IList), string minimalTlsVersion = default(string), string publicNetworkAccess = default(string), string workspaceFeature = default(string), string primaryUserAssignedIdentityId = default(string), string keyId = default(string), ServerExternalAdministrator administrators = default(ServerExternalAdministrator)) + /// Whether or not to + /// restrict outbound network access for this server. Value is + /// optional but if passed in, must be 'Enabled' or 'Disabled'. + /// Possible values include: 'Enabled', 'Disabled' + public Server(string location, string id = default(string), string name = default(string), string type = default(string), IDictionary tags = default(IDictionary), ResourceIdentity identity = default(ResourceIdentity), string kind = default(string), string administratorLogin = default(string), string administratorLoginPassword = default(string), string version = default(string), string state = default(string), string fullyQualifiedDomainName = default(string), IList privateEndpointConnections = default(IList), string minimalTlsVersion = default(string), string publicNetworkAccess = default(string), string workspaceFeature = default(string), string primaryUserAssignedIdentityId = default(string), System.Guid? federatedClientId = default(System.Guid?), string keyId = default(string), ServerExternalAdministrator administrators = default(ServerExternalAdministrator), string restrictOutboundNetworkAccess = default(string)) : base(location, id, name, type, tags) { Identity = identity; @@ -83,8 +89,10 @@ public Server() PublicNetworkAccess = publicNetworkAccess; WorkspaceFeature = workspaceFeature; PrimaryUserAssignedIdentityId = primaryUserAssignedIdentityId; + FederatedClientId = federatedClientId; KeyId = keyId; Administrators = administrators; + RestrictOutboundNetworkAccess = restrictOutboundNetworkAccess; CustomInit(); } @@ -174,6 +182,12 @@ public Server() [JsonProperty(PropertyName = "properties.primaryUserAssignedIdentityId")] public string PrimaryUserAssignedIdentityId { get; set; } + /// + /// Gets or sets the Client id used for cross tenant CMK scenario + /// + [JsonProperty(PropertyName = "properties.federatedClientId")] + public System.Guid? FederatedClientId { get; set; } + /// /// Gets or sets a CMK URI of the key to use for encryption. /// @@ -186,6 +200,14 @@ public Server() [JsonProperty(PropertyName = "properties.administrators")] public ServerExternalAdministrator Administrators { get; set; } + /// + /// Gets or sets whether or not to restrict outbound network access for + /// this server. Value is optional but if passed in, must be 'Enabled' + /// or 'Disabled'. Possible values include: 'Enabled', 'Disabled' + /// + [JsonProperty(PropertyName = "properties.restrictOutboundNetworkAccess")] + public string RestrictOutboundNetworkAccess { get; set; } + /// /// Validate the object. /// diff --git a/sdk/sqlmanagement/Microsoft.Azure.Management.Sql/src/Generated/Models/ServerPublicNetworkAccess.cs b/sdk/sqlmanagement/Microsoft.Azure.Management.Sql/src/Generated/Models/ServerNetworkAccessFlag.cs similarity index 84% rename from sdk/sqlmanagement/Microsoft.Azure.Management.Sql/src/Generated/Models/ServerPublicNetworkAccess.cs rename to sdk/sqlmanagement/Microsoft.Azure.Management.Sql/src/Generated/Models/ServerNetworkAccessFlag.cs index 6b611e0db6a3c..d7c9fb5f6c515 100644 --- a/sdk/sqlmanagement/Microsoft.Azure.Management.Sql/src/Generated/Models/ServerPublicNetworkAccess.cs +++ b/sdk/sqlmanagement/Microsoft.Azure.Management.Sql/src/Generated/Models/ServerNetworkAccessFlag.cs @@ -12,9 +12,9 @@ namespace Microsoft.Azure.Management.Sql.Models { /// - /// Defines values for ServerPublicNetworkAccess. + /// Defines values for ServerNetworkAccessFlag. /// - public static class ServerPublicNetworkAccess + public static class ServerNetworkAccessFlag { public const string Enabled = "Enabled"; public const string Disabled = "Disabled"; diff --git a/sdk/sqlmanagement/Microsoft.Azure.Management.Sql/src/Generated/Models/ServerUpdate.cs b/sdk/sqlmanagement/Microsoft.Azure.Management.Sql/src/Generated/Models/ServerUpdate.cs index 4c909033e7c52..b5b5251a2142d 100644 --- a/sdk/sqlmanagement/Microsoft.Azure.Management.Sql/src/Generated/Models/ServerUpdate.cs +++ b/sdk/sqlmanagement/Microsoft.Azure.Management.Sql/src/Generated/Models/ServerUpdate.cs @@ -56,12 +56,18 @@ public ServerUpdate() /// Possible values include: 'Connected', 'Disconnected' /// The resource id of a /// user assigned identity to be used by default. + /// The Client id used for cross tenant + /// CMK scenario /// A CMK URI of the key to use for /// encryption. /// The Azure Active Directory identity of /// the server. + /// Whether or not to + /// restrict outbound network access for this server. Value is + /// optional but if passed in, must be 'Enabled' or 'Disabled'. + /// Possible values include: 'Enabled', 'Disabled' /// Resource tags. - public ServerUpdate(ResourceIdentity identity = default(ResourceIdentity), string administratorLogin = default(string), string administratorLoginPassword = default(string), string version = default(string), string state = default(string), string fullyQualifiedDomainName = default(string), IList privateEndpointConnections = default(IList), string minimalTlsVersion = default(string), string publicNetworkAccess = default(string), string workspaceFeature = default(string), string primaryUserAssignedIdentityId = default(string), string keyId = default(string), ServerExternalAdministrator administrators = default(ServerExternalAdministrator), IDictionary tags = default(IDictionary)) + public ServerUpdate(ResourceIdentity identity = default(ResourceIdentity), string administratorLogin = default(string), string administratorLoginPassword = default(string), string version = default(string), string state = default(string), string fullyQualifiedDomainName = default(string), IList privateEndpointConnections = default(IList), string minimalTlsVersion = default(string), string publicNetworkAccess = default(string), string workspaceFeature = default(string), string primaryUserAssignedIdentityId = default(string), System.Guid? federatedClientId = default(System.Guid?), string keyId = default(string), ServerExternalAdministrator administrators = default(ServerExternalAdministrator), string restrictOutboundNetworkAccess = default(string), IDictionary tags = default(IDictionary)) { Identity = identity; AdministratorLogin = administratorLogin; @@ -74,8 +80,10 @@ public ServerUpdate() PublicNetworkAccess = publicNetworkAccess; WorkspaceFeature = workspaceFeature; PrimaryUserAssignedIdentityId = primaryUserAssignedIdentityId; + FederatedClientId = federatedClientId; KeyId = keyId; Administrators = administrators; + RestrictOutboundNetworkAccess = restrictOutboundNetworkAccess; Tags = tags; CustomInit(); } @@ -159,6 +167,12 @@ public ServerUpdate() [JsonProperty(PropertyName = "properties.primaryUserAssignedIdentityId")] public string PrimaryUserAssignedIdentityId { get; set; } + /// + /// Gets or sets the Client id used for cross tenant CMK scenario + /// + [JsonProperty(PropertyName = "properties.federatedClientId")] + public System.Guid? FederatedClientId { get; set; } + /// /// Gets or sets a CMK URI of the key to use for encryption. /// @@ -171,6 +185,14 @@ public ServerUpdate() [JsonProperty(PropertyName = "properties.administrators")] public ServerExternalAdministrator Administrators { get; set; } + /// + /// Gets or sets whether or not to restrict outbound network access for + /// this server. Value is optional but if passed in, must be 'Enabled' + /// or 'Disabled'. Possible values include: 'Enabled', 'Disabled' + /// + [JsonProperty(PropertyName = "properties.restrictOutboundNetworkAccess")] + public string RestrictOutboundNetworkAccess { get; set; } + /// /// Gets or sets resource tags. /// diff --git a/sdk/sqlmanagement/Microsoft.Azure.Management.Sql/src/Generated/SdkInfo_SqlManagementClient.cs b/sdk/sqlmanagement/Microsoft.Azure.Management.Sql/src/Generated/SdkInfo_SqlManagementClient.cs index 09a622eda8f3c..55f49a8f8ec00 100644 --- a/sdk/sqlmanagement/Microsoft.Azure.Management.Sql/src/Generated/SdkInfo_SqlManagementClient.cs +++ b/sdk/sqlmanagement/Microsoft.Azure.Management.Sql/src/Generated/SdkInfo_SqlManagementClient.cs @@ -126,7 +126,7 @@ public static IEnumerable> ApiInfo_SqlManagementCl new Tuple("Sql", "ServerTrustGroups", "2020-11-01-preview"), new Tuple("Sql", "ServerUsages", "2014-04-01"), new Tuple("Sql", "ServerVulnerabilityAssessments", "2020-11-01-preview"), - new Tuple("Sql", "Servers", "2020-11-01-preview"), + new Tuple("Sql", "Servers", "2021-02-01-preview"), new Tuple("Sql", "ServiceObjectives", "2014-04-01"), new Tuple("Sql", "SqlAgent", "2020-11-01-preview"), new Tuple("Sql", "SubscriptionUsages", "2020-11-01-preview"), @@ -145,16 +145,5 @@ public static IEnumerable> ApiInfo_SqlManagementCl }.AsEnumerable(); } } - // BEGIN: Code Generation Metadata Section - public static readonly String AutoRestVersion = "v2"; - public static readonly String AutoRestBootStrapperVersion = "autorest@2.0.4413"; - public static readonly String AutoRestCmdExecuted = "cmd.exe /c autorest.cmd https://github.com/Azure/azure-rest-api-specs/blob/master/specification/sql/resource-manager/readme.md --csharp --version=v2 --reflect-api-versions --csharp-sdks-folder=D:\\repos\\azure-sdk-for-net\\sdk"; - public static readonly String GithubForkName = "Azure"; - public static readonly String GithubBranchName = "master"; - public static readonly String GithubCommidId = "1c801aa70be460b277f1d81f9cced889ca5008fe"; - public static readonly String CodeGenerationErrors = ""; - public static readonly String GithubRepoName = "azure-rest-api-specs"; - // END: Code Generation Metadata Section } } - diff --git a/sdk/sqlmanagement/Microsoft.Azure.Management.Sql/src/Generated/ServersOperations.cs b/sdk/sqlmanagement/Microsoft.Azure.Management.Sql/src/Generated/ServersOperations.cs index ebaad2d115dbb..f21820645a6b1 100644 --- a/sdk/sqlmanagement/Microsoft.Azure.Management.Sql/src/Generated/ServersOperations.cs +++ b/sdk/sqlmanagement/Microsoft.Azure.Management.Sql/src/Generated/ServersOperations.cs @@ -91,7 +91,7 @@ internal ServersOperations(SqlManagementClient client) { throw new ValidationException(ValidationRules.CannotBeNull, "this.Client.SubscriptionId"); } - string apiVersion = "2020-11-01-preview"; + string apiVersion = "2021-02-01-preview"; // Tracing bool _shouldTrace = ServiceClientTracing.IsEnabled; string _invocationId = null; @@ -292,7 +292,7 @@ internal ServersOperations(SqlManagementClient client) { throw new ValidationException(ValidationRules.CannotBeNull, "this.Client.SubscriptionId"); } - string apiVersion = "2020-11-01-preview"; + string apiVersion = "2021-02-01-preview"; // Tracing bool _shouldTrace = ServiceClientTracing.IsEnabled; string _invocationId = null; @@ -555,7 +555,7 @@ internal ServersOperations(SqlManagementClient client) { throw new ValidationException(ValidationRules.CannotBeNull, "this.Client.SubscriptionId"); } - string apiVersion = "2020-11-01-preview"; + string apiVersion = "2021-02-01-preview"; // Tracing bool _shouldTrace = ServiceClientTracing.IsEnabled; string _invocationId = null; @@ -773,7 +773,7 @@ internal ServersOperations(SqlManagementClient client) { throw new ValidationException(ValidationRules.CannotBeNull, "this.Client.SubscriptionId"); } - string apiVersion = "2020-11-01-preview"; + string apiVersion = "2021-02-01-preview"; // Tracing bool _shouldTrace = ServiceClientTracing.IsEnabled; string _invocationId = null; @@ -982,7 +982,7 @@ internal ServersOperations(SqlManagementClient client) { throw new ValidationException(ValidationRules.CannotBeNull, "this.Client.SubscriptionId"); } - string apiVersion = "2020-11-01-preview"; + string apiVersion = "2021-02-01-preview"; // Tracing bool _shouldTrace = ServiceClientTracing.IsEnabled; string _invocationId = null; @@ -1199,7 +1199,7 @@ internal ServersOperations(SqlManagementClient client) { throw new ValidationException(ValidationRules.CannotBeNull, "this.Client.SubscriptionId"); } - string apiVersion = "2020-11-01-preview"; + string apiVersion = "2021-02-01-preview"; // Tracing bool _shouldTrace = ServiceClientTracing.IsEnabled; string _invocationId = null; @@ -1383,7 +1383,7 @@ internal ServersOperations(SqlManagementClient client) { throw new ValidationException(ValidationRules.CannotBeNull, "this.Client.SubscriptionId"); } - string apiVersion = "2020-11-01-preview"; + string apiVersion = "2021-02-01-preview"; // Tracing bool _shouldTrace = ServiceClientTracing.IsEnabled; string _invocationId = null; @@ -1596,7 +1596,7 @@ internal ServersOperations(SqlManagementClient client) { throw new ValidationException(ValidationRules.CannotBeNull, "this.Client.SubscriptionId"); } - string apiVersion = "2020-11-01-preview"; + string apiVersion = "2021-02-01-preview"; // Tracing bool _shouldTrace = ServiceClientTracing.IsEnabled; string _invocationId = null; diff --git a/sdk/sqlmanagement/Microsoft.Azure.Management.Sql/src/Generated/SqlManagementClient.cs b/sdk/sqlmanagement/Microsoft.Azure.Management.Sql/src/Generated/SqlManagementClient.cs index ea914af18ccd6..c4bd489f97886 100644 --- a/sdk/sqlmanagement/Microsoft.Azure.Management.Sql/src/Generated/SqlManagementClient.cs +++ b/sdk/sqlmanagement/Microsoft.Azure.Management.Sql/src/Generated/SqlManagementClient.cs @@ -557,11 +557,6 @@ public partial class SqlManagementClient : ServiceClient, I /// public virtual IServerOperations ServerOperations { get; private set; } - /// - /// Gets the IServersOperations. - /// - public virtual IServersOperations Servers { get; private set; } - /// /// Gets the IServerSecurityAlertPoliciesOperations. /// @@ -667,6 +662,11 @@ public partial class SqlManagementClient : ServiceClient, I /// public virtual IRestorableDroppedManagedDatabasesOperations RestorableDroppedManagedDatabases { get; private set; } + /// + /// Gets the IServersOperations. + /// + public virtual IServersOperations Servers { get; private set; } + /// /// Gets the IUsagesOperations. /// @@ -1010,7 +1010,6 @@ private void Initialize() ServerDnsAliases = new ServerDnsAliasesOperations(this); ServerKeys = new ServerKeysOperations(this); ServerOperations = new ServerOperations(this); - Servers = new ServersOperations(this); ServerSecurityAlertPolicies = new ServerSecurityAlertPoliciesOperations(this); ServerTrustGroups = new ServerTrustGroupsOperations(this); ServerVulnerabilityAssessments = new ServerVulnerabilityAssessmentsOperations(this); @@ -1032,6 +1031,7 @@ private void Initialize() OutboundFirewallRules = new OutboundFirewallRulesOperations(this); RestorableDroppedDatabases = new RestorableDroppedDatabasesOperations(this); RestorableDroppedManagedDatabases = new RestorableDroppedManagedDatabasesOperations(this); + Servers = new ServersOperations(this); Usages = new UsagesOperations(this); BaseUri = new System.Uri("https://management.azure.com"); AcceptLanguage = "en-US";