Skip to content

Commit 2056e85

Browse files
begoldsmHovsep
authored andcommitted
Update PowerShell to use the latest SDK and bug fixes (#2670)
* Update PowerShell to use the latest SDK Missed DataLakeStore upgrade. Updates for file and folder download. Tests will be in the next iteration. Fixing the connection manager overwriting. This is important to ensure that we have enough connections available for ingress/egress scenarios, and it must be set before the client is first used. Updating the help for ADLS to include new download. Signed local package for testing. Add full path property to ADLS Items Remove private package. Official is published Adding official package from nuget. Missed one disable of tracing. Fixing ADL tests and re-running them This enables ADL tests to run during CI and gets them totally updated. fix to always copy ADL session records. Add links to AzureRM.Resources.ps1 Following the pattern from compute tests. Adding records directory info for mock server This is a requirement for the tests to be discovered when run in playback mode. Fix ADL tests and update changelog This updates the change log to reflect the changes made Fixes to datetime offset for listing jobs fix to import/export logic due to inverted parameters. Missed one of the test updates test fixes for ADLA and ADLS Add specific exclusion for ADL acls Inside of ACLs we allow ":", which breaks the playback of tests, since it encodes ":", which results in a missed match in the recorded json (which contains the colon). This fixes that so playback does not encode colons for paths that start with: /webhdfs/v1/?aclspec Fix missing resume and bad merge. update to latest version of the store package. Update to latest ADLS sdks replace local feed with signed package Update tests and fix null reference bug for ADLA * Remove test package. * Update ADLS Filesystem tests and SDK package There was an SDK package mismatch caught by tests. Fixing this.
1 parent 324d57e commit 2056e85

File tree

28 files changed

+16596
-11342
lines changed

28 files changed

+16596
-11342
lines changed

src/ResourceManager/DataLakeAnalytics/Commands.DataLakeAnalytics.Test/ScenarioTests/AdlaAliasTests.ps1

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ function Test-DataLakeAnalyticsAccount
5858
Assert-True {Test-AdlAnalyticsAccount -Name $accountName}
5959

6060
# Updating Account
61-
$tagsToUpdate = @{"Name" = "TestTag"; "Value" = "TestUpdate"}
61+
$tagsToUpdate = @{"TestTag" = "TestUpdate"}
6262
$accountUpdated = Set-AdlAnalyticsAccount -ResourceGroupName $resourceGroupName -Name $accountName -Tags $tagsToUpdate
6363

6464
Assert-AreEqual $accountName $accountUpdated.Name
@@ -306,7 +306,7 @@ function Test-NegativeDataLakeAnalyticsAccount
306306
Assert-Throws {New-AdlAnalyticsAccount -ResourceGroupName $resourceGroupName -Name $accountName -Location $location -DefaultDataLakeStore $dataLakeAccountName}
307307

308308
# attempt to update a non-existent account
309-
$tagsToUpdate = @{"Name" = "TestTag"; "Value" = "TestUpdate"}
309+
$tagsToUpdate = @{"TestTag" = "TestUpdate"}
310310
Assert-Throws {Set-AdlAnalyticsAccount -ResourceGroupName $resourceGroupName -Name $fakeaccountName -Tags $tagsToUpdate}
311311

312312
# attempt to get a non-existent account

src/ResourceManager/DataLakeAnalytics/Commands.DataLakeAnalytics.Test/ScenarioTests/AdlaTests.ps1

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ function Test-DataLakeAnalyticsAccount
5858
Assert-True {Test-AzureRMDataLakeAnalyticsAccount -Name $accountName}
5959

6060
# Updating Account
61-
$tagsToUpdate = @{"Name" = "TestTag"; "Value" = "TestUpdate"}
61+
$tagsToUpdate = @{"TestTag" = "TestUpdate"}
6262
$accountUpdated = Set-AzureRmDataLakeAnalyticsAccount -ResourceGroupName $resourceGroupName -Name $accountName -Tags $tagsToUpdate
6363

6464
Assert-AreEqual $accountName $accountUpdated.Name
@@ -305,7 +305,7 @@ function Test-NegativeDataLakeAnalyticsAccount
305305
Assert-Throws {New-AzureRmDataLakeAnalyticsAccount -ResourceGroupName $resourceGroupName -Name $accountName -Location $location -DefaultDataLakeStore $dataLakeAccountName}
306306

307307
# attempt to update a non-existent account
308-
$tagsToUpdate = @{"Name" = "TestTag"; "Value" = "TestUpdate"}
308+
$tagsToUpdate = @{"TestTag" = "TestUpdate"}
309309
Assert-Throws {Set-AzureRmDataLakeAnalyticsAccount -ResourceGroupName $resourceGroupName -Name $fakeaccountName -Tags $tagsToUpdate}
310310

311311
# attempt to get a non-existent account

src/ResourceManager/DataLakeAnalytics/Commands.DataLakeAnalytics.Test/SessionRecords/Microsoft.Azure.Commands.DataLakeAnalytics.Test.ScenarioTests.AdlaAliasTests/TestAdlaAccount.json

Lines changed: 798 additions & 882 deletions
Large diffs are not rendered by default.

src/ResourceManager/DataLakeAnalytics/Commands.DataLakeAnalytics.Test/SessionRecords/Microsoft.Azure.Commands.DataLakeAnalytics.Test.ScenarioTests.AdlaAliasTests/TestAdlaCatalog.json

Lines changed: 720 additions & 2079 deletions
Large diffs are not rendered by default.

src/ResourceManager/DataLakeAnalytics/Commands.DataLakeAnalytics.Test/SessionRecords/Microsoft.Azure.Commands.DataLakeAnalytics.Test.ScenarioTests.AdlaAliasTests/TestAdlaJob.json

Lines changed: 280 additions & 280 deletions
Large diffs are not rendered by default.

src/ResourceManager/DataLakeAnalytics/Commands.DataLakeAnalytics.Test/SessionRecords/Microsoft.Azure.Commands.DataLakeAnalytics.Test.ScenarioTests.AdlaAliasTests/TestNegativeAdlaAccount.json

Lines changed: 305 additions & 410 deletions
Large diffs are not rendered by default.

src/ResourceManager/DataLakeAnalytics/Commands.DataLakeAnalytics.Test/SessionRecords/Microsoft.Azure.Commands.DataLakeAnalytics.Test.ScenarioTests.AdlaAliasTests/TestNegativeAdlaJob.json

Lines changed: 310 additions & 241 deletions
Large diffs are not rendered by default.

src/ResourceManager/DataLakeAnalytics/Commands.DataLakeAnalytics.Test/SessionRecords/Microsoft.Azure.Commands.DataLakeAnalytics.Test.ScenarioTests.AdlaTests/TestAdlaAccount.json

Lines changed: 815 additions & 815 deletions
Large diffs are not rendered by default.

src/ResourceManager/DataLakeAnalytics/Commands.DataLakeAnalytics.Test/SessionRecords/Microsoft.Azure.Commands.DataLakeAnalytics.Test.ScenarioTests.AdlaTests/TestAdlaCatalog.json

Lines changed: 10079 additions & 3380 deletions
Large diffs are not rendered by default.

src/ResourceManager/DataLakeAnalytics/Commands.DataLakeAnalytics.Test/SessionRecords/Microsoft.Azure.Commands.DataLakeAnalytics.Test.ScenarioTests.AdlaTests/TestAdlaJob.json

Lines changed: 350 additions & 374 deletions
Large diffs are not rendered by default.

src/ResourceManager/DataLakeAnalytics/Commands.DataLakeAnalytics.Test/SessionRecords/Microsoft.Azure.Commands.DataLakeAnalytics.Test.ScenarioTests.AdlaTests/TestNegativeAdlaAccount.json

Lines changed: 280 additions & 280 deletions
Large diffs are not rendered by default.

src/ResourceManager/DataLakeAnalytics/Commands.DataLakeAnalytics.Test/SessionRecords/Microsoft.Azure.Commands.DataLakeAnalytics.Test.ScenarioTests.AdlaTests/TestNegativeAdlaJob.json

Lines changed: 368 additions & 272 deletions
Large diffs are not rendered by default.

src/ResourceManager/DataLakeAnalytics/Commands.DataLakeAnalytics/Models/DataLakeAnalyticsClient.cs

Lines changed: 15 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ public class DataLakeAnalyticsClient
3333
private readonly DataLakeAnalyticsCatalogManagementClient _catalogClient;
3434
private readonly DataLakeAnalyticsJobManagementClient _jobClient;
3535
private readonly Guid _subscriptionId;
36+
private static Queue<Guid> jobIdQueue;
3637

3738

3839
/// <summary>
@@ -41,15 +42,27 @@ public class DataLakeAnalyticsClient
4142
/// <value>
4243
/// The job identifier queue.
4344
/// </value>
44-
public static Queue<Guid> JobIdQueue { get; set; }
45+
public static Queue<Guid> JobIdQueue
46+
{
47+
get
48+
{
49+
if (jobIdQueue == null)
50+
{
51+
jobIdQueue = new Queue<Guid>();
52+
}
53+
54+
return jobIdQueue;
55+
}
56+
set { jobIdQueue = value; }
57+
}
4558

4659
public DataLakeAnalyticsClient(AzureContext context)
4760
{
4861
if (context == null)
4962
{
5063
throw new ApplicationException(Resources.InvalidDefaultSubscription);
5164
}
52-
JobIdQueue = new Queue<Guid>();
65+
5366
_accountClient = DataLakeAnalyticsCmdletBase.CreateAdlaClient<DataLakeAnalyticsAccountManagementClient>(context,
5467
AzureEnvironment.Endpoint.ResourceManager);
5568
_subscriptionId = context.Subscription.Id;

src/ResourceManager/DataLakeStore/Commands.DataLakeStore.Test/Commands.DataLakeStore.Test.csproj

Lines changed: 4 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -63,13 +63,11 @@
6363
<Private>True</Private>
6464
</Reference>
6565
<Reference Include="Microsoft.Azure.Management.DataLake.Store, Version=0.12.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
66-
<SpecificVersion>False</SpecificVersion>
67-
<HintPath>..\..\..\packages\Microsoft.Azure.Management.DataLake.Store.0.12.2-preview\lib\net45\Microsoft.Azure.Management.DataLake.Store.dll</HintPath>
66+
<HintPath>..\..\..\packages\Microsoft.Azure.Management.DataLake.Store.0.12.4-preview\lib\net45\Microsoft.Azure.Management.DataLake.Store.dll</HintPath>
6867
<Private>True</Private>
6968
</Reference>
70-
<Reference Include="Microsoft.Azure.Management.DataLake.StoreUploader, Version=0.10.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
71-
<SpecificVersion>False</SpecificVersion>
72-
<HintPath>..\..\..\packages\Microsoft.Azure.Management.DataLake.StoreUploader.0.10.4-preview\lib\net45\Microsoft.Azure.Management.DataLake.StoreUploader.dll</HintPath>
69+
<Reference Include="Microsoft.Azure.Management.DataLake.StoreUploader, Version=0.10.0.0, Culture=neutral, processorArchitecture=MSIL">
70+
<HintPath>..\..\..\packages\Microsoft.Azure.Management.DataLake.StoreUploader.0.10.5-preview\lib\net45\Microsoft.Azure.Management.DataLake.StoreUploader.dll</HintPath>
7371
<Private>True</Private>
7472
</Reference>
7573
<Reference Include="Microsoft.Azure.Management.ResourceManager, Version=1.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35, processorArchitecture=MSIL">
@@ -248,4 +246,4 @@
248246
<ItemGroup />
249247
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
250248
<Import Project="$(SolutionDir)\.nuget\NuGet.targets" Condition="Exists('$(SolutionDir)\.nuget\NuGet.targets')" />
251-
</Project>
249+
</Project>

src/ResourceManager/DataLakeStore/Commands.DataLakeStore.Test/ScenarioTests/AdlsAliasTests.ps1

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ function Test-DataLakeStoreAccount
5252
Assert-True {Test-AdlStore -Name $accountName}
5353

5454
# Updating Account
55-
$tagsToUpdate = @{"Name" = "TestTag"; "Value" = "TestUpdate"}
55+
$tagsToUpdate = @{"TestTag" = "TestUpdate"}
5656
$accountUpdated = Set-AdlStore -ResourceGroupName $resourceGroupName -Name $accountName -Tags $tagsToUpdate
5757

5858
Assert-AreEqual $accountName $accountUpdated.Name
@@ -415,7 +415,7 @@ function Test-NegativeDataLakeStoreAccount
415415
Assert-Throws {New-AdlStore -ResourceGroupName $resourceGroupName -Name $accountName -Location $location}
416416

417417
# attempt to update a non-existent account
418-
$tagsToUpdate = @{"Name" = "TestTag"; "Value" = "TestUpdate"}
418+
$tagsToUpdate = @{"TestTag" = "TestUpdate"}
419419
Assert-Throws {Set-AdlStore -ResourceGroupName $resourceGroupName -Name $fakeaccountName -Tags $tagsToUpdate}
420420

421421
# attempt to get a non-existent account

src/ResourceManager/DataLakeStore/Commands.DataLakeStore.Test/ScenarioTests/AdlsTests.ps1

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ function Test-DataLakeStoreAccount
5252
Assert-True {Test-AzureRMDataLakeStoreAccount -Name $accountName}
5353

5454
# Updating Account
55-
$tagsToUpdate = @{"Name" = "TestTag"; "Value" = "TestUpdate"}
55+
$tagsToUpdate = @{"TestTag" = "TestUpdate"}
5656
$accountUpdated = Set-AzureRmDataLakeStoreAccount -ResourceGroupName $resourceGroupName -Name $accountName -Tags $tagsToUpdate
5757

5858
Assert-AreEqual $accountName $accountUpdated.Name
@@ -415,7 +415,7 @@ function Test-NegativeDataLakeStoreAccount
415415
Assert-Throws {New-AzureRmDataLakeStoreAccount -ResourceGroupName $resourceGroupName -Name $accountName -Location $location}
416416

417417
# attempt to update a non-existent account
418-
$tagsToUpdate = @{"Name" = "TestTag"; "Value" = "TestUpdate"}
418+
$tagsToUpdate = @{"TestTag" = "TestUpdate"}
419419
Assert-Throws {Set-AzureRmDataLakeStoreAccount -ResourceGroupName $resourceGroupName -Name $fakeaccountName -Tags $tagsToUpdate}
420420

421421
# attempt to get a non-existent account

0 commit comments

Comments
 (0)