diff --git a/src/Sql/Sql.Test/Sql.Test.csproj b/src/Sql/Sql.Test/Sql.Test.csproj index 44695b6a93e1..81dc3f8d5149 100644 --- a/src/Sql/Sql.Test/Sql.Test.csproj +++ b/src/Sql/Sql.Test/Sql.Test.csproj @@ -19,7 +19,7 @@ - + diff --git a/src/Sql/Sql/AdvancedThreatProtection/Cmdlet/DisableAzureSqlManagedInstanceAdvancedDataSecurity.cs b/src/Sql/Sql/AdvancedDataSecurity/Cmdlet/DisableAzureSqlManagedInstanceAdvancedDataSecurity.cs similarity index 100% rename from src/Sql/Sql/AdvancedThreatProtection/Cmdlet/DisableAzureSqlManagedInstanceAdvancedDataSecurity.cs rename to src/Sql/Sql/AdvancedDataSecurity/Cmdlet/DisableAzureSqlManagedInstanceAdvancedDataSecurity.cs diff --git a/src/Sql/Sql/AdvancedThreatProtection/Cmdlet/DisableAzureSqlServerAdvancedDataSecurity.cs b/src/Sql/Sql/AdvancedDataSecurity/Cmdlet/DisableAzureSqlServerAdvancedDataSecurity.cs similarity index 91% rename from src/Sql/Sql/AdvancedThreatProtection/Cmdlet/DisableAzureSqlServerAdvancedDataSecurity.cs rename to src/Sql/Sql/AdvancedDataSecurity/Cmdlet/DisableAzureSqlServerAdvancedDataSecurity.cs index 8b31d8e4cf12..c606149aafcb 100644 --- a/src/Sql/Sql/AdvancedThreatProtection/Cmdlet/DisableAzureSqlServerAdvancedDataSecurity.cs +++ b/src/Sql/Sql/AdvancedDataSecurity/Cmdlet/DisableAzureSqlServerAdvancedDataSecurity.cs @@ -12,15 +12,17 @@ // limitations under the License. // ---------------------------------------------------------------------------------- +using Microsoft.Azure.Commands.Common.Authentication.Abstractions; using Microsoft.Azure.Commands.Sql.AdvancedThreatProtection.Model; +using Microsoft.WindowsAzure.Commands.Common.CustomAttributes; using System.Management.Automation; -using Microsoft.Azure.Commands.Common.Authentication.Abstractions; namespace Microsoft.Azure.Commands.Sql.AdvancedThreatProtection.Cmdlet { /// /// Disables the Advanced Data Security of a specific server. /// + [GenericBreakingChange("Disable-AzSqlServerAdvancedThreatProtection alias will be removed in an upcoming breaking change release", "9.0.0")] [Cmdlet("Disable", ResourceManager.Common.AzureRMConstants.AzureRMPrefix + "SqlServerAdvancedDataSecurity", SupportsShouldProcess = true), OutputType(typeof(ServerAdvancedDataSecurityPolicyModel))] [Alias("Disable-AzSqlServerAdvancedThreatProtection")] public class DisableAzureSqlServerAdvancedDataSecurity : SqlServerAdvancedDataSecurityCmdletBase diff --git a/src/Sql/Sql/AdvancedThreatProtection/Cmdlet/EnableAzureSqlManagedInstanceAdvancedDataSecurity.cs b/src/Sql/Sql/AdvancedDataSecurity/Cmdlet/EnableAzureSqlManagedInstanceAdvancedDataSecurity.cs similarity index 100% rename from src/Sql/Sql/AdvancedThreatProtection/Cmdlet/EnableAzureSqlManagedInstanceAdvancedDataSecurity.cs rename to src/Sql/Sql/AdvancedDataSecurity/Cmdlet/EnableAzureSqlManagedInstanceAdvancedDataSecurity.cs diff --git a/src/Sql/Sql/AdvancedThreatProtection/Cmdlet/EnableAzureSqlServerAdvancedDataSecurity.cs b/src/Sql/Sql/AdvancedDataSecurity/Cmdlet/EnableAzureSqlServerAdvancedDataSecurity.cs similarity index 95% rename from src/Sql/Sql/AdvancedThreatProtection/Cmdlet/EnableAzureSqlServerAdvancedDataSecurity.cs rename to src/Sql/Sql/AdvancedDataSecurity/Cmdlet/EnableAzureSqlServerAdvancedDataSecurity.cs index 2b661fd3fa5b..7bb2da60ec78 100644 --- a/src/Sql/Sql/AdvancedThreatProtection/Cmdlet/EnableAzureSqlServerAdvancedDataSecurity.cs +++ b/src/Sql/Sql/AdvancedDataSecurity/Cmdlet/EnableAzureSqlServerAdvancedDataSecurity.cs @@ -12,19 +12,21 @@ // limitations under the License. // ---------------------------------------------------------------------------------- -using Microsoft.Azure.Commands.Sql.AdvancedThreatProtection.Model; -using System.Management.Automation; using Microsoft.Azure.Commands.Common.Authentication.Abstractions; +using Microsoft.Azure.Commands.Sql.AdvancedThreatProtection.Model; using Microsoft.Azure.Commands.Sql.Server.Adapter; using Microsoft.Azure.Commands.Sql.Server.Model; using Microsoft.Azure.Commands.Sql.VulnerabilityAssessment.Model; using Microsoft.Azure.Commands.Sql.VulnerabilityAssessment.Services; +using Microsoft.WindowsAzure.Commands.Common.CustomAttributes; +using System.Management.Automation; namespace Microsoft.Azure.Commands.Sql.AdvancedThreatProtection.Cmdlet { /// /// Enables the Advanced Threat Protection of a specific server. /// + [GenericBreakingChange("Enable-AzSqlServerAdvancedThreatProtection alias will be removed in an upcoming breaking change release", "9.0.0")] [Cmdlet("Enable", ResourceManager.Common.AzureRMConstants.AzureRMPrefix + "SqlServerAdvancedDataSecurity", SupportsShouldProcess = true), OutputType(typeof(ServerAdvancedDataSecurityPolicyModel))] [Alias("Enable-AzSqlServerAdvancedThreatProtection")] public class EnableAzureSqlServerAdvancedDataSecurity : SqlServerAdvancedDataSecurityCmdletBase diff --git a/src/Sql/Sql/AdvancedThreatProtection/Cmdlet/GetAzureSqlManagedInstanceAdvancedDataSecurityPolicy.cs b/src/Sql/Sql/AdvancedDataSecurity/Cmdlet/GetAzureSqlManagedInstanceAdvancedDataSecurityPolicy.cs similarity index 100% rename from src/Sql/Sql/AdvancedThreatProtection/Cmdlet/GetAzureSqlManagedInstanceAdvancedDataSecurityPolicy.cs rename to src/Sql/Sql/AdvancedDataSecurity/Cmdlet/GetAzureSqlManagedInstanceAdvancedDataSecurityPolicy.cs diff --git a/src/Sql/Sql/AdvancedThreatProtection/Cmdlet/GetAzureSqlServerAdvancedDataSecurityPolicy.cs b/src/Sql/Sql/AdvancedDataSecurity/Cmdlet/GetAzureSqlServerAdvancedDataSecurityPolicy.cs similarity index 91% rename from src/Sql/Sql/AdvancedThreatProtection/Cmdlet/GetAzureSqlServerAdvancedDataSecurityPolicy.cs rename to src/Sql/Sql/AdvancedDataSecurity/Cmdlet/GetAzureSqlServerAdvancedDataSecurityPolicy.cs index 5b2344220676..fa0146f40b03 100644 --- a/src/Sql/Sql/AdvancedThreatProtection/Cmdlet/GetAzureSqlServerAdvancedDataSecurityPolicy.cs +++ b/src/Sql/Sql/AdvancedDataSecurity/Cmdlet/GetAzureSqlServerAdvancedDataSecurityPolicy.cs @@ -13,6 +13,7 @@ // ---------------------------------------------------------------------------------- using Microsoft.Azure.Commands.Sql.AdvancedThreatProtection.Model; +using Microsoft.WindowsAzure.Commands.Common.CustomAttributes; using System.Management.Automation; namespace Microsoft.Azure.Commands.Sql.AdvancedThreatProtection.Cmdlet @@ -20,6 +21,7 @@ namespace Microsoft.Azure.Commands.Sql.AdvancedThreatProtection.Cmdlet /// /// Returns the Advanced Threat Protection policy of a specific server. /// + [GenericBreakingChange("Get-AzSqlServerAdvancedThreatProtectionPolicy alias will be removed in an upcoming breaking change release", "9.0.0")] [Cmdlet("Get", ResourceManager.Common.AzureRMConstants.AzureRMPrefix + "SqlServerAdvancedDataSecurityPolicy"), OutputType(typeof(ServerAdvancedDataSecurityPolicyModel))] [Alias("Get-AzSqlServerAdvancedThreatProtectionPolicy")] public class GetAzureSqlServerAdvancedDataSecurityPolicy : SqlServerAdvancedDataSecurityCmdletBase diff --git a/src/Sql/Sql/AdvancedThreatProtection/Cmdlet/SqlManagedInstanceAdvancedDataSecurityCmdletBase.cs b/src/Sql/Sql/AdvancedDataSecurity/Cmdlet/SqlManagedInstanceAdvancedDataSecurityCmdletBase.cs similarity index 100% rename from src/Sql/Sql/AdvancedThreatProtection/Cmdlet/SqlManagedInstanceAdvancedDataSecurityCmdletBase.cs rename to src/Sql/Sql/AdvancedDataSecurity/Cmdlet/SqlManagedInstanceAdvancedDataSecurityCmdletBase.cs diff --git a/src/Sql/Sql/AdvancedThreatProtection/Cmdlet/SqlServerAdvancedDataSecurityCmdletBase.cs b/src/Sql/Sql/AdvancedDataSecurity/Cmdlet/SqlServerAdvancedDataSecurityCmdletBase.cs similarity index 100% rename from src/Sql/Sql/AdvancedThreatProtection/Cmdlet/SqlServerAdvancedDataSecurityCmdletBase.cs rename to src/Sql/Sql/AdvancedDataSecurity/Cmdlet/SqlServerAdvancedDataSecurityCmdletBase.cs diff --git a/src/Sql/Sql/AdvancedThreatProtection/Model/ManagedInstanceAdvancedDataSecurityPolicyModel.cs b/src/Sql/Sql/AdvancedDataSecurity/Model/ManagedInstanceAdvancedDataSecurityPolicyModel.cs similarity index 100% rename from src/Sql/Sql/AdvancedThreatProtection/Model/ManagedInstanceAdvancedDataSecurityPolicyModel.cs rename to src/Sql/Sql/AdvancedDataSecurity/Model/ManagedInstanceAdvancedDataSecurityPolicyModel.cs diff --git a/src/Sql/Sql/AdvancedThreatProtection/Model/ServerAdvancedDataSecurityPolicyModel.cs b/src/Sql/Sql/AdvancedDataSecurity/Model/ServerAdvancedDataSecurityPolicyModel.cs similarity index 100% rename from src/Sql/Sql/AdvancedThreatProtection/Model/ServerAdvancedDataSecurityPolicyModel.cs rename to src/Sql/Sql/AdvancedDataSecurity/Model/ServerAdvancedDataSecurityPolicyModel.cs diff --git a/src/Sql/Sql/AdvancedThreatProtection/Services/SqlAdvancedDataSecurityAdapter.cs b/src/Sql/Sql/AdvancedDataSecurity/Services/SqlAdvancedDataSecurityAdapter.cs similarity index 100% rename from src/Sql/Sql/AdvancedThreatProtection/Services/SqlAdvancedDataSecurityAdapter.cs rename to src/Sql/Sql/AdvancedDataSecurity/Services/SqlAdvancedDataSecurityAdapter.cs diff --git a/src/Sql/Sql/AdvancedThreatProtection/Templates/DeployInstanceVaTemplate.json b/src/Sql/Sql/AdvancedDataSecurity/Templates/DeployInstanceVaTemplate.json similarity index 100% rename from src/Sql/Sql/AdvancedThreatProtection/Templates/DeployInstanceVaTemplate.json rename to src/Sql/Sql/AdvancedDataSecurity/Templates/DeployInstanceVaTemplate.json diff --git a/src/Sql/Sql/AdvancedThreatProtection/Templates/DeployServerVaTemplate.json b/src/Sql/Sql/AdvancedDataSecurity/Templates/DeployServerVaTemplate.json similarity index 100% rename from src/Sql/Sql/AdvancedThreatProtection/Templates/DeployServerVaTemplate.json rename to src/Sql/Sql/AdvancedDataSecurity/Templates/DeployServerVaTemplate.json diff --git a/src/Sql/Sql/Az.Sql.psd1 b/src/Sql/Sql/Az.Sql.psd1 index a78943db0c34..71bb6637971b 100644 --- a/src/Sql/Sql/Az.Sql.psd1 +++ b/src/Sql/Sql/Az.Sql.psd1 @@ -306,7 +306,6 @@ AliasesToExport = 'Get-AzSqlDatabaseServerAuditingPolicy', 'Clear-AzSqlInstanceDatabaseVulnerabilityAssessmentSetting', 'Enable-AzSqlServerAdvancedThreatProtection', 'Disable-AzSqlServerAdvancedThreatProtection', - 'Get-AzSqlServerAdvancedThreatProtectionSetting', 'Get-AzSqlServerThreatDetectionSetting', 'Remove-AzSqlServerThreatDetectionSetting', 'Set-AzSqlServerThreatDetectionSetting', diff --git a/src/Sql/Sql/ChangeLog.md b/src/Sql/Sql/ChangeLog.md index ee5523dd2b04..7b87037de9c1 100644 --- a/src/Sql/Sql/ChangeLog.md +++ b/src/Sql/Sql/ChangeLog.md @@ -46,6 +46,8 @@ - `Remove-AzSqlInstanceLink` - `Set-AzSqlInstanceLink` * Added support for DataWarehouse cross tenant and cross subscription restore operations to `Restore-AzSqlDatabase` cmdlet +* Upgrading to usage of .NET SDK 3.1.0-preview +* Declare breaking changes for the AdvancedDataSecurity and AdvancedThreatProtection cmdlets to be effective from 9.0.0. ## Version 3.7.1 * Deprecation of Get-AzSqlDatabaseTransparentDataEncryptionActivity cmdlet diff --git a/src/Sql/Sql/Sql.csproj b/src/Sql/Sql/Sql.csproj index 0cb4765c6f7d..8c8f48e77440 100644 --- a/src/Sql/Sql/Sql.csproj +++ b/src/Sql/Sql/Sql.csproj @@ -11,17 +11,17 @@ - - + + - - + + - + diff --git a/src/Sql/Sql/ThreatDetection/Cmdlet/GetAzureSqlDatabaseThreatDetection.cs b/src/Sql/Sql/ThreatDetection/Cmdlet/GetAzureSqlDatabaseThreatDetection.cs index 9c1870188d50..5b2a7df8bec3 100644 --- a/src/Sql/Sql/ThreatDetection/Cmdlet/GetAzureSqlDatabaseThreatDetection.cs +++ b/src/Sql/Sql/ThreatDetection/Cmdlet/GetAzureSqlDatabaseThreatDetection.cs @@ -13,17 +13,19 @@ // ---------------------------------------------------------------------------------- using Microsoft.Azure.Commands.Sql.ThreatDetection.Model; -using System.Management.Automation; using Microsoft.WindowsAzure.Commands.Common.CustomAttributes; +using System.Management.Automation; namespace Microsoft.Azure.Commands.Sql.ThreatDetection.Cmdlet { /// /// Returns the advanced threat protection settings of a specific database. /// - [GenericBreakingChange("Get-AzSqlDatabaseAdvancedThreatProtectionSettings alias will be removed in an upcoming breaking change release", "3.0.0")] + [CmdletOutputBreakingChange( + deprecatedCmdletOutputTypeName: typeof(DatabaseThreatDetectionPolicyModel), + deprecateByVersion: "9.0.0", + ReplacementCmdletOutputTypeName = "DatabaseAdvancedThreatProtectionSettingsModel")] [Cmdlet("Get", ResourceManager.Common.AzureRMConstants.AzureRMPrefix + "SqlDatabaseAdvancedThreatProtectionSetting", SupportsShouldProcess = true),OutputType(typeof(DatabaseThreatDetectionPolicyModel))] - [Alias("Get-AzSqlDatabaseAdvancedThreatProtectionSettings")] public class AzureRmSqlDatabaseThreatDetectionPolicy : SqlDatabaseThreatDetectionCmdletBase { /// diff --git a/src/Sql/Sql/ThreatDetection/Cmdlet/GetAzureSqlServerThreatDetection.cs b/src/Sql/Sql/ThreatDetection/Cmdlet/GetAzureSqlServerThreatDetection.cs index e3cc8890f738..4e6e39e4ac1e 100644 --- a/src/Sql/Sql/ThreatDetection/Cmdlet/GetAzureSqlServerThreatDetection.cs +++ b/src/Sql/Sql/ThreatDetection/Cmdlet/GetAzureSqlServerThreatDetection.cs @@ -21,9 +21,11 @@ namespace Microsoft.Azure.Commands.Sql.ThreatDetection.Cmdlet /// /// Returns the advanced threat protection settings of a specific server. /// - [GenericBreakingChange("Get-AzSqlServerAdvancedThreatProtectionSettings alias will be removed in an upcoming breaking change release", "3.0.0")] + [CmdletOutputBreakingChange( + deprecatedCmdletOutputTypeName: typeof(ServerThreatDetectionPolicyModel), + deprecateByVersion: "9.0.0", + ReplacementCmdletOutputTypeName = "ServerAdvancedThreatProtectionSettingsModel")] [Cmdlet("Get", ResourceManager.Common.AzureRMConstants.AzureRMPrefix + "SqlServerAdvancedThreatProtectionSetting", SupportsShouldProcess = true), OutputType(typeof(ServerThreatDetectionPolicyModel))] - [Alias("Get-AzSqlServerAdvancedThreatProtectionSettings")] public class AzureRmSqlServerThreatDetectionPolicy : SqlServerThreatDetectionCmdletBase { /// diff --git a/src/Sql/Sql/ThreatDetection/Cmdlet/RemoveSqlDatabaseThreatDetection.cs b/src/Sql/Sql/ThreatDetection/Cmdlet/RemoveSqlDatabaseThreatDetection.cs index 3a10a67a2b22..0335daaa72dc 100644 --- a/src/Sql/Sql/ThreatDetection/Cmdlet/RemoveSqlDatabaseThreatDetection.cs +++ b/src/Sql/Sql/ThreatDetection/Cmdlet/RemoveSqlDatabaseThreatDetection.cs @@ -21,9 +21,8 @@ namespace Microsoft.Azure.Commands.Sql.ThreatDetection.Cmdlet /// /// Clears advanced threat protection on a specific database. /// - [GenericBreakingChange("Remove-AzSqlDatabaseAdvancedThreatProtectionSettings alias will be removed in an upcoming breaking change release", "3.0.0")] + [GenericBreakingChange("Clear-AzSqlDatabaseAdvancedThreatProtectionSetting cmdlet will be removed in an upcoming breaking change release", "9.0.0")] [Cmdlet("Clear", ResourceManager.Common.AzureRMConstants.AzureRMPrefix + "SqlDatabaseAdvancedThreatProtectionSetting", SupportsShouldProcess = true),OutputType(typeof(DatabaseThreatDetectionPolicyModel))] - [Alias("Remove-AzSqlDatabaseAdvancedThreatProtectionSettings")] public class AzureRmSqlDatabaseThreatDetection : SqlDatabaseThreatDetectionCmdletBase { /// diff --git a/src/Sql/Sql/ThreatDetection/Cmdlet/RemoveSqlServerThreatDetection.cs b/src/Sql/Sql/ThreatDetection/Cmdlet/RemoveSqlServerThreatDetection.cs index 6491f84f96c3..85f57061a54c 100644 --- a/src/Sql/Sql/ThreatDetection/Cmdlet/RemoveSqlServerThreatDetection.cs +++ b/src/Sql/Sql/ThreatDetection/Cmdlet/RemoveSqlServerThreatDetection.cs @@ -21,9 +21,8 @@ namespace Microsoft.Azure.Commands.Sql.ThreatDetection.Cmdlet /// /// Clears advanced threat protection on a specific server. /// - [GenericBreakingChange("Remove-AzSqlServerAdvancedThreatProtectionSettings alias will be removed in an upcoming breaking change release", "3.0.0")] + [GenericBreakingChange("Clear-AzSqlServerAdvancedThreatProtectionSetting cmdlet will be removed in an upcoming breaking change release", "9.0.0")] [Cmdlet("Clear", ResourceManager.Common.AzureRMConstants.AzureRMPrefix + "SqlServerAdvancedThreatProtectionSetting", SupportsShouldProcess = true), OutputType(typeof(ServerThreatDetectionPolicyModel))] - [Alias("Remove-AzSqlServerAdvancedThreatProtectionSettings")] public class AzureRmSqlServerThreatDetection : SqlServerThreatDetectionCmdletBase { /// diff --git a/src/Sql/Sql/ThreatDetection/Cmdlet/SetAzureSqlDatabaseThreatDetection.cs b/src/Sql/Sql/ThreatDetection/Cmdlet/SetAzureSqlDatabaseThreatDetection.cs index b8ea6a0421d7..ae70870dfe95 100644 --- a/src/Sql/Sql/ThreatDetection/Cmdlet/SetAzureSqlDatabaseThreatDetection.cs +++ b/src/Sql/Sql/ThreatDetection/Cmdlet/SetAzureSqlDatabaseThreatDetection.cs @@ -14,17 +14,15 @@ using Microsoft.Azure.Commands.ResourceManager.Common.ArgumentCompleters; using Microsoft.Azure.Commands.Sql.ThreatDetection.Model; -using System.Management.Automation; using Microsoft.WindowsAzure.Commands.Common.CustomAttributes; +using System.Management.Automation; namespace Microsoft.Azure.Commands.Sql.ThreatDetection.Cmdlet { /// /// Updates the advanced threat protection properties for a specific database. /// - [GenericBreakingChange("Set-AzSqlDatabaseAdvancedThreatProtectionSettings alias will be removed in an upcoming breaking change release", "3.0.0")] [Cmdlet("Update", ResourceManager.Common.AzureRMConstants.AzureRMPrefix + "SqlDatabaseAdvancedThreatProtectionSetting", SupportsShouldProcess = true), OutputType(typeof(DatabaseThreatDetectionPolicyModel))] - [Alias("Set-AzSqlDatabaseAdvancedThreatProtectionSettings")] public class SetAzureSqlDatabaseThreatDetection : SqlDatabaseThreatDetectionCmdletBase { /// @@ -36,12 +34,14 @@ public class SetAzureSqlDatabaseThreatDetection : SqlDatabaseThreatDetectionCmdl /// /// Gets or sets the Threat Detection Email Addresses /// + [CmdletParameterBreakingChange("NotificationRecipientsEmails", deprecateByVersion: "9.0.0")] [Parameter(Mandatory = false, ValueFromPipelineByPropertyName = true, HelpMessage = "A semicolon separated list of email addresses to send the alerts to")] public string NotificationRecipientsEmails { get; set; } /// /// Gets or sets the whether to email administrators. /// + [CmdletParameterBreakingChange("EmailAdmins", deprecateByVersion: "9.0.0")] [Parameter(Mandatory = false, ValueFromPipelineByPropertyName = true, HelpMessage = "Defines whether to email administrators")] [ValidateNotNullOrEmpty] public bool? EmailAdmins { get; set; } @@ -49,6 +49,7 @@ public class SetAzureSqlDatabaseThreatDetection : SqlDatabaseThreatDetectionCmdl /// /// Gets or sets the names of the detection types to filter. /// + [CmdletParameterBreakingChange("ExcludedDetectionType", deprecateByVersion: "9.0.0")] [Parameter(Mandatory = false, ValueFromPipelineByPropertyName = true, HelpMessage = "Detection types to exclude")] [PSArgumentCompleter(DetectionType.None, DetectionType.Sql_Injection, @@ -62,6 +63,7 @@ public class SetAzureSqlDatabaseThreatDetection : SqlDatabaseThreatDetectionCmdl /// /// Gets or sets the name of the storage account to use. /// + [CmdletParameterBreakingChange("StorageAccountName", deprecateByVersion: "9.0.0")] [Parameter(Mandatory = false, ValueFromPipelineByPropertyName = true, HelpMessage = "The name of the storage account")] [ValidateNotNullOrEmpty] public string StorageAccountName { get; set; } @@ -69,6 +71,7 @@ public class SetAzureSqlDatabaseThreatDetection : SqlDatabaseThreatDetectionCmdl /// /// Gets or sets the number of retention days for the audit logs table. /// + [CmdletParameterBreakingChange("RetentionInDays", deprecateByVersion: "9.0.0")] [Parameter(Mandatory = false, ValueFromPipelineByPropertyName = true, HelpMessage = "The number of retention days for the audit logs")] [ValidateNotNullOrEmpty] diff --git a/src/Sql/Sql/ThreatDetection/Cmdlet/SetAzureSqlServerThreatDetection.cs b/src/Sql/Sql/ThreatDetection/Cmdlet/SetAzureSqlServerThreatDetection.cs index 4681abad7f95..519b7100c5b4 100644 --- a/src/Sql/Sql/ThreatDetection/Cmdlet/SetAzureSqlServerThreatDetection.cs +++ b/src/Sql/Sql/ThreatDetection/Cmdlet/SetAzureSqlServerThreatDetection.cs @@ -14,17 +14,15 @@ using Microsoft.Azure.Commands.ResourceManager.Common.ArgumentCompleters; using Microsoft.Azure.Commands.Sql.ThreatDetection.Model; -using System.Management.Automation; using Microsoft.WindowsAzure.Commands.Common.CustomAttributes; +using System.Management.Automation; namespace Microsoft.Azure.Commands.Sql.ThreatDetection.Cmdlet { /// /// Updates the advanced threat protection properties for a specific server. /// - [GenericBreakingChange("Set-AzSqlServerAdvancedThreatProtectionSettings alias will be removed in an upcoming breaking change release", "3.0.0")] [Cmdlet("Update", ResourceManager.Common.AzureRMConstants.AzureRMPrefix + "SqlServerAdvancedThreatProtectionSetting", SupportsShouldProcess = true), OutputType(typeof(ServerThreatDetectionPolicyModel))] - [Alias("Set-AzSqlServerAdvancedThreatProtectionSettings")] public class SetAzureSqlServerThreatDetection : SqlServerThreatDetectionCmdletBase { /// @@ -36,12 +34,14 @@ public class SetAzureSqlServerThreatDetection : SqlServerThreatDetectionCmdletBa /// /// Gets or sets the Threat Detection Email Addresses /// + [CmdletParameterBreakingChange("NotificationRecipientsEmails", deprecateByVersion: "9.0.0")] [Parameter(Mandatory = false, ValueFromPipelineByPropertyName = true, HelpMessage = "A semicolon separated list of email addresses to send the alerts to")] public string NotificationRecipientsEmails { get; set; } /// /// Gets or sets the whether to email administrators. /// + [CmdletParameterBreakingChange("EmailAdmins", deprecateByVersion: "9.0.0")] [Parameter(Mandatory = false, ValueFromPipelineByPropertyName = true, HelpMessage = "Defines whether to email administrators")] [ValidateNotNullOrEmpty] public bool? EmailAdmins { get; set; } @@ -49,6 +49,7 @@ public class SetAzureSqlServerThreatDetection : SqlServerThreatDetectionCmdletBa /// /// Gets or sets the names of the detection types to filter. /// + [CmdletParameterBreakingChange("ExcludedDetectionType", deprecateByVersion: "9.0.0")] [Parameter(Mandatory = false, ValueFromPipelineByPropertyName = true, HelpMessage = "Detection types to exclude")] [PSArgumentCompleter(DetectionType.None, DetectionType.Sql_Injection, @@ -62,6 +63,7 @@ public class SetAzureSqlServerThreatDetection : SqlServerThreatDetectionCmdletBa /// /// Gets or sets the name of the storage account to use. /// + [CmdletParameterBreakingChange("StorageAccountName", deprecateByVersion: "9.0.0")] [Parameter(Mandatory = false, ValueFromPipelineByPropertyName = true, HelpMessage = "The name of the storage account")] [ValidateNotNullOrEmpty] public string StorageAccountName { get; set; } @@ -69,6 +71,7 @@ public class SetAzureSqlServerThreatDetection : SqlServerThreatDetectionCmdletBa /// /// Gets or sets the number of retention days for the audit logs table. /// + [CmdletParameterBreakingChange("RetentionInDays", deprecateByVersion: "9.0.0")] [Parameter(Mandatory = false, ValueFromPipelineByPropertyName = true, HelpMessage = "The number of retention days for the audit logs")] [ValidateNotNullOrEmpty]