Skip to content

Commit 6c9b8f1

Browse files
committed
Deprecate Get/Set LTR vault cmdlets
1 parent 767a705 commit 6c9b8f1

File tree

5 files changed

+9
-2
lines changed

5 files changed

+9
-2
lines changed

src/ResourceManager/Sql/Commands.Sql.Test/ScenarioTests/DatabaseBackupTests.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,7 @@ public void TestRestorePointInTimeBackup()
6767
RunPowerShellTest("Test-RestorePointInTimeBackup");
6868
}
6969
}
70+
#if !NETSTANDARD
7071
[Fact]
7172
[Trait(Category.AcceptanceType, Category.CheckIn)]
7273
public void TestServerBackupLongTermRetentionVault()
@@ -78,6 +79,7 @@ public void TestServerBackupLongTermRetentionVault()
7879
RunPowerShellTest("Test-ServerBackupLongTermRetentionVault");
7980
}
8081
}
82+
#endif
8183
[Fact(Skip = "LTR-V1 restore service is retiring in Prod.")]
8284
[Trait(Category.AcceptanceType, Category.CheckIn)]
8385
public void TestRestoreLongTermRetentionBackup()

src/ResourceManager/Sql/Commands.Sql/Az.Sql.psd1

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -137,9 +137,7 @@ CmdletsToExport = 'Get-AzSqlDatabaseTransparentDataEncryption',
137137
'Remove-AzSqlDatabaseLongTermRetentionBackup',
138138
'Get-AzSqlDeletedDatabaseBackup',
139139
'Get-AzSqlDatabaseGeoBackup',
140-
'Get-AzSqlServerBackupLongTermRetentionVault',
141140
'Restore-AzSqlDatabase',
142-
'Set-AzSqlServerBackupLongTermRetentionVault',
143141
'Get-AzSqlDatabaseRestorePoints',
144142
'Get-AzSqlDatabaseAuditingPolicy',
145143
'Get-AzSqlServerAuditingPolicy',

src/ResourceManager/Sql/Commands.Sql/ChangeLog.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,9 @@
1919
-->
2020
## Current Release
2121
* Fixed issue with default resource groups not being set.
22+
* Deprecated unsupported LongTermRetention cmdlets:
23+
* Get-AzureRmSqlServerBackupLongTermRetentionVault
24+
* Set-AzureRmSqlServerBackupLongTermRetentionVault
2225

2326
## Version 4.11.1
2427
* Updated to the latest version of the Azure ClientRuntime.

src/ResourceManager/Sql/Commands.Sql/Database Backup/Cmdlet/GetAzureSqlServerBackupLongTermRetentionVault.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,9 +17,11 @@
1717
using System.Management.Automation;
1818
using Microsoft.Azure.Commands.Sql.Backup.Model;
1919
using Microsoft.Azure.Commands.Sql.Database.Model;
20+
using Microsoft.WindowsAzure.Commands.Common.CustomAttributes;
2021

2122
namespace Microsoft.Azure.Commands.Sql.Backup.Cmdlet
2223
{
24+
[CmdletDeprecation]
2325
[Cmdlet("Get", ResourceManager.Common.AzureRMConstants.AzureRMPrefix + "SqlServerBackupLongTermRetentionVault", SupportsShouldProcess = true)]
2426
[OutputType(typeof(AzureSqlServerBackupLongTermRetentionVaultModel))]
2527
public class GetAzureSqlServerBackupLongTermRetentionVault : AzureSqlServerBackupLongTermRetentionVaultCmdletBase

src/ResourceManager/Sql/Commands.Sql/Database Backup/Cmdlet/SetAzureSqlServerBackupLongTermRetentionVault.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,12 +18,14 @@
1818
using System.Management.Automation;
1919
using Microsoft.Azure.Commands.Sql.Backup.Model;
2020
using Microsoft.Azure.Commands.Sql.Database.Model;
21+
using Microsoft.WindowsAzure.Commands.Common.CustomAttributes;
2122

2223
namespace Microsoft.Azure.Commands.Sql.Backup.Cmdlet
2324
{
2425
/// <summary>
2526
/// Cmdlet to create or update a new Azure Sql Server backup archival vault
2627
/// </summary>
28+
[CmdletDeprecation]
2729
[Cmdlet("Set", ResourceManager.Common.AzureRMConstants.AzureRMPrefix + "SqlServerBackupLongTermRetentionVault",SupportsShouldProcess = true,ConfirmImpact = ConfirmImpact.Low), OutputType(typeof(AzureSqlServerBackupLongTermRetentionVaultModel))]
2830
public class SetAzureSqlServerBackupLongTermRetentionVault : AzureSqlServerBackupLongTermRetentionVaultCmdletBase
2931
{

0 commit comments

Comments
 (0)