From fef3fb57e68f5f588662a7f41a87c56eb4be96a7 Mon Sep 17 00:00:00 2001 From: Liliia Sabitova <107196662+LiliaSabitova@users.noreply.github.com> Date: Wed, 17 May 2023 08:31:08 +0200 Subject: [PATCH] Revert PR 4220 "Upgrade vss api netcore version, has BuildXL changes" (#4278) --- src/Agent.Listener/Agent.Listener.csproj | 1 - src/Agent.PluginHost/Agent.PluginHost.csproj | 1 - src/Agent.Plugins/Agent.Plugins.csproj | 1 - src/Agent.Sdk/Agent.Sdk.csproj | 3 ++- src/Agent.Sdk/Util/PlatformUtil.cs | 4 ++-- src/Agent.Worker/Agent.Worker.csproj | 2 +- src/Common.props | 2 +- .../Blob/BlobFileInfo.cs | 2 +- .../Blob/BlobStoreUtils.cs | 4 ++-- .../Microsoft.VisualStudio.Services.Agent.csproj | 3 ++- src/Test/L1/Mock/FakeJobServer.cs | 2 +- src/Test/Test.csproj | 5 +---- 12 files changed, 13 insertions(+), 17 deletions(-) diff --git a/src/Agent.Listener/Agent.Listener.csproj b/src/Agent.Listener/Agent.Listener.csproj index e9d2241960..dbd3e18546 100644 --- a/src/Agent.Listener/Agent.Listener.csproj +++ b/src/Agent.Listener/Agent.Listener.csproj @@ -4,7 +4,6 @@ Exe - true diff --git a/src/Agent.PluginHost/Agent.PluginHost.csproj b/src/Agent.PluginHost/Agent.PluginHost.csproj index 7aed7f31dd..f68fc56128 100644 --- a/src/Agent.PluginHost/Agent.PluginHost.csproj +++ b/src/Agent.PluginHost/Agent.PluginHost.csproj @@ -4,7 +4,6 @@ Exe - true diff --git a/src/Agent.Plugins/Agent.Plugins.csproj b/src/Agent.Plugins/Agent.Plugins.csproj index e58759a558..f71a17560d 100644 --- a/src/Agent.Plugins/Agent.Plugins.csproj +++ b/src/Agent.Plugins/Agent.Plugins.csproj @@ -4,7 +4,6 @@ Library - true diff --git a/src/Agent.Sdk/Agent.Sdk.csproj b/src/Agent.Sdk/Agent.Sdk.csproj index 950d9bbcd5..a002a2320e 100644 --- a/src/Agent.Sdk/Agent.Sdk.csproj +++ b/src/Agent.Sdk/Agent.Sdk.csproj @@ -3,15 +3,16 @@ Library - true + + \ No newline at end of file diff --git a/src/Agent.Sdk/Util/PlatformUtil.cs b/src/Agent.Sdk/Util/PlatformUtil.cs index 9cb7304310..37590a1f89 100644 --- a/src/Agent.Sdk/Util/PlatformUtil.cs +++ b/src/Agent.Sdk/Util/PlatformUtil.cs @@ -391,7 +391,7 @@ public static bool DetectDockerContainer() } } } - catch (Exception) + catch (Exception ex) { // Logging exception will be handled by JobRunner throw; @@ -411,7 +411,7 @@ public static bool DetectAzureVM() if (metadataProvider.HasMetadata()) isAzureVM = true; } - catch (Exception) + catch (Exception ex) { // Logging exception will be handled by JobRunner throw; diff --git a/src/Agent.Worker/Agent.Worker.csproj b/src/Agent.Worker/Agent.Worker.csproj index 3328d9276a..9172bf1f75 100644 --- a/src/Agent.Worker/Agent.Worker.csproj +++ b/src/Agent.Worker/Agent.Worker.csproj @@ -4,7 +4,6 @@ Exe - true @@ -15,6 +14,7 @@ + diff --git a/src/Common.props b/src/Common.props index 535fa1bddc..f86030796a 100644 --- a/src/Common.props +++ b/src/Common.props @@ -10,7 +10,7 @@ OS_UNKNOWN ARCH_UNKNOWN - 0.5.183-private + 0.5.181-private $(CodeAnalysis) false diff --git a/src/Microsoft.VisualStudio.Services.Agent/Blob/BlobFileInfo.cs b/src/Microsoft.VisualStudio.Services.Agent/Blob/BlobFileInfo.cs index 56b61483f6..9e1906547e 100644 --- a/src/Microsoft.VisualStudio.Services.Agent/Blob/BlobFileInfo.cs +++ b/src/Microsoft.VisualStudio.Services.Agent/Blob/BlobFileInfo.cs @@ -13,7 +13,7 @@ public DedupIdentifier DedupId { get { - return Node.GetDedupIdentifier(); + return Node.GetDedupIdentifier(HashType.Dedup64K); } } public bool Success { get; set; } diff --git a/src/Microsoft.VisualStudio.Services.Agent/Blob/BlobStoreUtils.cs b/src/Microsoft.VisualStudio.Services.Agent/Blob/BlobStoreUtils.cs index 56928caca8..662ed20a92 100644 --- a/src/Microsoft.VisualStudio.Services.Agent/Blob/BlobStoreUtils.cs +++ b/src/Microsoft.VisualStudio.Services.Agent/Blob/BlobStoreUtils.cs @@ -43,7 +43,7 @@ public static class BlobStoreUtils foreach (var file in fileNodes.Where(x => x.Success)) { // ChunkHelper uses 64k block default size - var dedupId = file.Node.GetDedupIdentifier(); + var dedupId = file.Node.GetDedupIdentifier(HashType.Dedup64K); fileDedupIds[dedupId] = file.Path; } @@ -180,7 +180,7 @@ private static DedupNode CreateNodeToUpload(IEnumerable nodes) var chunk = await ChunkerHelper.CreateFromFileAsync(FileSystem.Instance, itemPath, cancellationToken, false); var rootNode = new DedupNode(new[] { chunk }); // ChunkHelper uses 64k block default size - var dedupId = rootNode.GetDedupIdentifier(); + var dedupId = rootNode.GetDedupIdentifier(HashType.Dedup64K); // Setup upload session to keep file for at mimimum one day // Blobs will need to be associated with the server with an ID ref otherwise they will be diff --git a/src/Microsoft.VisualStudio.Services.Agent/Microsoft.VisualStudio.Services.Agent.csproj b/src/Microsoft.VisualStudio.Services.Agent/Microsoft.VisualStudio.Services.Agent.csproj index 30103259b4..cc8e51db3d 100644 --- a/src/Microsoft.VisualStudio.Services.Agent/Microsoft.VisualStudio.Services.Agent.csproj +++ b/src/Microsoft.VisualStudio.Services.Agent/Microsoft.VisualStudio.Services.Agent.csproj @@ -4,7 +4,6 @@ Library - true @@ -14,6 +13,8 @@ + + diff --git a/src/Test/L1/Mock/FakeJobServer.cs b/src/Test/L1/Mock/FakeJobServer.cs index c69c153457..c19de4341b 100644 --- a/src/Test/L1/Mock/FakeJobServer.cs +++ b/src/Test/L1/Mock/FakeJobServer.cs @@ -142,7 +142,7 @@ public Task UploadLogToBlobStore(Stream blob, string h UploadedAttachmentBlobFiles.Add(itemPath); var chunk = await ChunkerHelper.CreateFromFileAsync(FileSystem.Instance, itemPath, cancellationToken, false); var rootNode = new DedupNode(new[] { chunk }); - var dedupId = rootNode.GetDedupIdentifier(); + var dedupId = rootNode.GetDedupIdentifier(HashType.Dedup64K); return (dedupId, rootNode.TransitiveContentBytes); } diff --git a/src/Test/Test.csproj b/src/Test/Test.csproj index 3d4ff03b59..b3f8cf3b98 100644 --- a/src/Test/Test.csproj +++ b/src/Test/Test.csproj @@ -8,16 +8,13 @@ - - true - - +