Skip to content

Commit d7c7597

Browse files
committed
renamed DatabaseMaxSize to DatabaseMaxSizeBytes
Changed the ConfirmImpact to Medium and added SupportsShouldProcess = true
1 parent b440a00 commit d7c7597

File tree

7 files changed

+12
-12
lines changed

7 files changed

+12
-12
lines changed

src/ResourceManager/Sql/Commands.Sql.Test/ScenarioTests/ImportExportTests.ps1

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -82,7 +82,7 @@ function Test-ImportDatabase
8282
}
8383

8484
if($operationName -eq $import){
85-
$importResponse = New-AzureRmSqlDatabaseImport -ResourceGroupName $params.rgname -ServerName $params.serverName -DatabaseName $params.databaseName -StorageKeyType $params.storageKeyType -StorageKey $params.storageKey -StorageUri $params.importBacpacUri -AdministratorLogin $params.userName -AdministratorLoginPassword $secureString -Edition Standard -ServiceObjectiveName S0 -DatabaseMaxSize 5000000 -AuthenticationType Sql
85+
$importResponse = New-AzureRmSqlDatabaseImport -ResourceGroupName $params.rgname -ServerName $params.serverName -DatabaseName $params.databaseName -StorageKeyType $params.storageKeyType -StorageKey $params.storageKey -StorageUri $params.importBacpacUri -AdministratorLogin $params.userName -AdministratorLoginPassword $secureString -Edition Standard -ServiceObjectiveName S0 -DatabaseMaxSizeBytes 5000000 -AuthenticationType Sql
8686
Assert-NotNull $importResponse
8787
$operationStatusLink = $importResponse.OperationStatusLink
8888
}

src/ResourceManager/Sql/Commands.Sql/ImportExport/Cmdlet/GetAzureSqlDatabaseImportExportStatus.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ namespace Microsoft.Azure.Commands.Sql.ImportExport.Cmdlet
2323
/// <summary>
2424
/// Defines the AzureRmSqlDatabaseImportExportStatus cmdlet
2525
/// </summary>
26-
[Cmdlet(VerbsCommon.Get, "AzureRmSqlDatabaseImportExportStatus", ConfirmImpact = ConfirmImpact.Low)]
26+
[Cmdlet(VerbsCommon.Get, "AzureRmSqlDatabaseImportExportStatus", ConfirmImpact = ConfirmImpact.Medium, SupportsShouldProcess = true)]
2727
public class GetAzureSqlDatabaseImportExportStatus : AzureRMCmdlet
2828
{
2929
/// <summary>

src/ResourceManager/Sql/Commands.Sql/ImportExport/Cmdlet/NewAzureSqlDatabaseExport.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ namespace Microsoft.Azure.Commands.Sql.ImportExport.Cmdlet
2828
/// <summary>
2929
/// Defines the StartAzureSqlDatabaseExport cmdlet
3030
/// </summary>
31-
[Cmdlet(VerbsCommon.New, "AzureRmSqlDatabaseExport", ConfirmImpact = ConfirmImpact.Low)]
31+
[Cmdlet(VerbsCommon.New, "AzureRmSqlDatabaseExport", ConfirmImpact = ConfirmImpact.Medium, SupportsShouldProcess = true)]
3232
public class NewAzureSqlDatabaseExport : ImportExportCmdletBase
3333
{
3434
/// <summary>

src/ResourceManager/Sql/Commands.Sql/ImportExport/Cmdlet/NewAzureSqlDatabaseImport.cs

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ namespace Microsoft.Azure.Commands.Sql.ImportExport.Cmdlet
2626
/// <summary>
2727
/// Defines the AzureRmSqlDatabaseImport cmdlet
2828
/// </summary>
29-
[Cmdlet(VerbsCommon.New, "AzureRmSqlDatabaseImport", ConfirmImpact = ConfirmImpact.Low)]
29+
[Cmdlet(VerbsCommon.New, "AzureRmSqlDatabaseImport", ConfirmImpact = ConfirmImpact.Medium, SupportsShouldProcess = true)]
3030
public class NewAzureSqlDatabaseImport : ImportExportCmdletBase
3131
{
3232
/// <summary>
@@ -60,8 +60,8 @@ public string ServiceObjectiveName
6060
/// <summary>
6161
/// Gets or sets the maximum size for the newly imported database
6262
/// </summary>
63-
[Parameter(Mandatory = true, HelpMessage = "The maximum size for the newly imported database")]
64-
public int DatabaseMaxSize
63+
[Parameter(Mandatory = true, HelpMessage = "The maximum size in bytes for the newly imported database")]
64+
public int DatabaseMaxSizeBytes
6565
{
6666
get; set;
6767
}
@@ -110,7 +110,7 @@ protected override AzureSqlDatabaseImportExportBaseModel ApplyUserInputToModel(A
110110
StorageUri = StorageUri,
111111
Edition = Edition,
112112
ServiceObjectiveName = ServiceObjectiveName,
113-
DatabaseMaxSize = DatabaseMaxSize
113+
DatabaseMaxSizeBytes = DatabaseMaxSizeBytes
114114
};
115115
return exportRequest;
116116
}

src/ResourceManager/Sql/Commands.Sql/ImportExport/Model/AzureSqlDatabaseImportModel.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ public string ServiceObjectiveName
4545
/// <summary>
4646
/// Gets or sets the maximum size for the newly imported database
4747
/// </summary>
48-
public int DatabaseMaxSize
48+
public int DatabaseMaxSizeBytes
4949
{
5050
get; set;
5151
}

src/ResourceManager/Sql/Commands.Sql/ImportExport/Service/ImportExportDatabaseAdapter.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -84,7 +84,7 @@ public AzureSqlDatabaseImportExportBaseModel Import(AzureSqlDatabaseImportModel
8484
StorageKey = importRequest.StorageKey,
8585
StorageKeyType = importRequest.StorageKeyType.ToString(),
8686
StorageUri = importRequest.StorageUri,
87-
DatabaseMaxSize = importRequest.DatabaseMaxSize,
87+
DatabaseMaxSize = importRequest.DatabaseMaxSizeBytes,
8888
Edition = importRequest.Edition != Database.Model.DatabaseEdition.None ? importRequest.Edition.ToString() : string.Empty,
8989
ServiceObjectiveName = importRequest.ServiceObjectiveName,
9090
DatabaseName = importRequest.DatabaseName

src/ResourceManager/Sql/Commands.Sql/Microsoft.Azure.Commands.Sql.dll-Help.xml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8458,7 +8458,7 @@ ErrorMessage :</maml:para>
84588458
<command:parameterValue required="true" variableLength="false">String</command:parameterValue>
84598459
</command:parameter>
84608460
<command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="named">
8461-
<maml:name>DatabaseMaxSize</maml:name>
8461+
<maml:name>DatabaseMaxSizeBytes</maml:name>
84628462
<maml:description>
84638463
<maml:para>Specifies the maximum size for the newly imported database.</maml:para>
84648464
</maml:description>
@@ -8578,7 +8578,7 @@ ErrorMessage :</maml:para>
85788578
<dev:defaultValue></dev:defaultValue>
85798579
</command:parameter>
85808580
<command:parameter required="true" variableLength="false" globbing="false" pipelineInput="false" position="named">
8581-
<maml:name>DatabaseMaxSize</maml:name>
8581+
<maml:name>DatabaseMaxSizeBytes</maml:name>
85828582
<maml:description>
85838583
<maml:para>Specifies the maximum size for the newly imported database.</maml:para>
85848584
</maml:description>
@@ -8752,7 +8752,7 @@ ErrorMessage :</maml:para>
87528752
<maml:introduction>
87538753
<maml:paragraph>PS C:\&gt;</maml:paragraph>
87548754
</maml:introduction>
8755-
<dev:code>PS C:\&gt; New-AzureRmSqlDatabaseImport -ResourceGroupName &quot;resourcegroup01&quot; -ServerName &quot;server01&quot; -DatabaseName &quot;database01&quot; -StorageKeyType &quot;StorageAccessKey&quot; -StorageKey &quot;storagekey01&quot; -StorageUri &quot;http://account01.blob.core.windows.net/bacpacs/database01.bacpac&quot; -AdministratorLogin &quot;user&quot; -AdministratorLoginPassword $secureString -Edition Standard -ServiceObjectiveName S0 -DatabaseMaxSize 5000000</dev:code>
8755+
<dev:code>PS C:\&gt; New-AzureRmSqlDatabaseImport -ResourceGroupName &quot;resourcegroup01&quot; -ServerName &quot;server01&quot; -DatabaseName &quot;database01&quot; -StorageKeyType &quot;StorageAccessKey&quot; -StorageKey &quot;storagekey01&quot; -StorageUri &quot;http://account01.blob.core.windows.net/bacpacs/database01.bacpac&quot; -AdministratorLogin &quot;user&quot; -AdministratorLoginPassword $secureString -Edition Standard -ServiceObjectiveName S0 -DatabaseMaxSizeBytes 5000000</dev:code>
87568756
<dev:remarks>
87578757
<maml:para>This command creates an import request to import a bacpac to a new database.</maml:para>
87588758
<maml:para />

0 commit comments

Comments
 (0)