Skip to content

Commit 7256251

Browse files
authored
[Rollout] Production rollout 2024-11-25 (#4184)
2 parents 0227c76 + 0fdedf4 commit 7256251

File tree

302 files changed

+1535
-1041
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

302 files changed

+1535
-1041
lines changed

.config/dotnet-tools.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
"isRoot": true,
44
"tools": {
55
"microsoft.dnceng.secretmanager": {
6-
"version": "1.1.0-beta.24555.1",
6+
"version": "1.1.0-beta.24562.1",
77
"commands": [
88
"secret-manager"
99
]
@@ -15,7 +15,7 @@
1515
]
1616
},
1717
"microsoft.dnceng.configuration.bootstrap": {
18-
"version": "1.1.0-beta.24555.1",
18+
"version": "1.1.0-beta.24562.1",
1919
"commands": [
2020
"bootstrap-dnceng-configuration"
2121
]

.vault-config/product-construction-prod.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ secrets:
2828
name: BotAccount-dotnet-bot
2929
gitHubBotAccountName: dotnet-bot
3030

31-
dotnet-bot-maestro-auth-test-content-rw:
31+
dotnet-bot-maestro-auth-test-content-rw-pr-rw:
3232
type: github-access-token
3333
parameters:
3434
gitHubBotAccountSecret:

Directory.Packages.props

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -102,19 +102,19 @@
102102
<PackageVersion Include="Microsoft.Extensions.Configuration.Json" Version="8.0.0" />
103103
<PackageVersion Include="Microsoft.Extensions.Configuration.UserSecrets" Version="8.0.0" />
104104
<PackageVersion Include="Microsoft.Extensions.Configuration" Version="8.0.0" />
105-
<PackageVersion Include="Microsoft.Extensions.DependencyInjection.Abstractions" Version="8.0.1" />
106-
<PackageVersion Include="Microsoft.Extensions.DependencyInjection" Version="8.0.0" />
105+
<PackageVersion Include="Microsoft.Extensions.DependencyInjection.Abstractions" Version="8.0.2" />
106+
<PackageVersion Include="Microsoft.Extensions.DependencyInjection" Version="8.0.1" />
107107
<PackageVersion Include="Microsoft.Extensions.Hosting" Version="8.0.0" />
108108
<PackageVersion Include="Microsoft.Extensions.Http.Resilience" Version="8.0.0" />
109-
<PackageVersion Include="Microsoft.Extensions.Http" Version="8.0.0" />
110-
<PackageVersion Include="Microsoft.Extensions.Logging.Abstractions" Version="8.0.1" />
109+
<PackageVersion Include="Microsoft.Extensions.Http" Version="8.0.1" />
110+
<PackageVersion Include="Microsoft.Extensions.Logging.Abstractions" Version="8.0.2" />
111111
<PackageVersion Include="Microsoft.Extensions.Logging.ApplicationInsights" Version="2.22.0" />
112112
<PackageVersion Include="Microsoft.Extensions.Logging.Console" Version="8.0.0" />
113-
<PackageVersion Include="Microsoft.Extensions.Logging" Version="8.0.0" />
113+
<PackageVersion Include="Microsoft.Extensions.Logging" Version="8.0.1" />
114114
<PackageVersion Include="Microsoft.Extensions.Options" Version="8.0.2" />
115115
<PackageVersion Include="Microsoft.Extensions.ServiceDiscovery" Version="$(AspireVersion)" />
116-
<PackageVersion Include="Microsoft.FluentUI.AspNetCore.Components.Icons" Version="4.10.0" />
117-
<PackageVersion Include="Microsoft.FluentUI.AspNetCore.Components" Version="4.10.0" />
116+
<PackageVersion Include="Microsoft.FluentUI.AspNetCore.Components.Icons" Version="4.10.4" />
117+
<PackageVersion Include="Microsoft.FluentUI.AspNetCore.Components" Version="4.10.4" />
118118
<PackageVersion Include="Microsoft.Identity.Web" Version="2.18.2" />
119119
<PackageVersion Include="Microsoft.ServiceFabric.Actors" Version="5.2.1571" />
120120
<PackageVersion Include="Microsoft.ServiceFabric.AspNetCore.HttpSys" Version="5.2.1571" />
@@ -160,4 +160,4 @@
160160
<PackageVersion Include="Verify.NUnit" Version="19.6" />
161161
<PackageVersion Include="YamlDotNet" Version="16.0.0" />
162162
</ItemGroup>
163-
</Project>
163+
</Project>

azure-pipelines-product-construction-service.yml

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -268,4 +268,10 @@ stages:
268268
parameters:
269269
name: scenarioTests_Other
270270
displayName: Other tests
271-
testFilter: 'TestCategory!=GitHub&TestCategory!=AzDO'
271+
testFilter: 'TestCategory!=GitHub&TestCategory!=AzDO&TestCategory!=CodeFlow'
272+
273+
- template: /eng/templates/jobs/e2e-pcs-tests.yml
274+
parameters:
275+
name: scenarioTests_CodeFlow
276+
displayName: Code Flow tests
277+
testFilter: 'TestCategory=CodeFlow'

eng/Version.Details.xml

Lines changed: 16 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -91,37 +91,37 @@
9191
</Dependency>
9292
</ProductDependencies>
9393
<ToolsetDependencies>
94-
<Dependency Name="Microsoft.DotNet.Arcade.Sdk" Version="8.0.0-beta.24525.2">
94+
<Dependency Name="Microsoft.DotNet.Arcade.Sdk" Version="8.0.0-beta.24570.5">
9595
<Uri>https://github.com/dotnet/arcade</Uri>
96-
<Sha>24e02f80c5458d1f75240ae57fc2a98fb8a9022a</Sha>
96+
<Sha>3c7e11bf80279cde53a6251c4d0fa10e613fc739</Sha>
9797
</Dependency>
98-
<Dependency Name="Microsoft.DotNet.SignTool" Version="8.0.0-beta.24525.2">
98+
<Dependency Name="Microsoft.DotNet.SignTool" Version="8.0.0-beta.24570.5">
9999
<Uri>https://github.com/dotnet/arcade</Uri>
100-
<Sha>24e02f80c5458d1f75240ae57fc2a98fb8a9022a</Sha>
100+
<Sha>3c7e11bf80279cde53a6251c4d0fa10e613fc739</Sha>
101101
</Dependency>
102-
<Dependency Name="Microsoft.DotNet.Build.Tasks.Feed" Version="8.0.0-beta.24525.2">
102+
<Dependency Name="Microsoft.DotNet.Build.Tasks.Feed" Version="8.0.0-beta.24570.5">
103103
<Uri>https://github.com/dotnet/arcade</Uri>
104-
<Sha>24e02f80c5458d1f75240ae57fc2a98fb8a9022a</Sha>
104+
<Sha>3c7e11bf80279cde53a6251c4d0fa10e613fc739</Sha>
105105
</Dependency>
106-
<Dependency Name="Microsoft.DotNet.SwaggerGenerator.MSBuild" Version="8.0.0-beta.24525.2">
106+
<Dependency Name="Microsoft.DotNet.SwaggerGenerator.MSBuild" Version="8.0.0-beta.24570.5">
107107
<Uri>https://github.com/dotnet/arcade</Uri>
108-
<Sha>24e02f80c5458d1f75240ae57fc2a98fb8a9022a</Sha>
108+
<Sha>3c7e11bf80279cde53a6251c4d0fa10e613fc739</Sha>
109109
</Dependency>
110-
<Dependency Name="Microsoft.DotNet.Git.IssueManager" Version="8.0.0-beta.24525.2">
110+
<Dependency Name="Microsoft.DotNet.Git.IssueManager" Version="8.0.0-beta.24570.5">
111111
<Uri>https://github.com/dotnet/arcade</Uri>
112-
<Sha>24e02f80c5458d1f75240ae57fc2a98fb8a9022a</Sha>
112+
<Sha>3c7e11bf80279cde53a6251c4d0fa10e613fc739</Sha>
113113
</Dependency>
114-
<Dependency Name="Microsoft.DotNet.VersionTools" Version="8.0.0-beta.24525.2">
114+
<Dependency Name="Microsoft.DotNet.VersionTools" Version="8.0.0-beta.24570.5">
115115
<Uri>https://github.com/dotnet/arcade</Uri>
116-
<Sha>24e02f80c5458d1f75240ae57fc2a98fb8a9022a</Sha>
116+
<Sha>3c7e11bf80279cde53a6251c4d0fa10e613fc739</Sha>
117117
</Dependency>
118-
<Dependency Name="Microsoft.DncEng.SecretManager" Version="1.1.0-beta.24555.1">
118+
<Dependency Name="Microsoft.DncEng.SecretManager" Version="1.1.0-beta.24562.1">
119119
<Uri>https://github.com/dotnet/dnceng</Uri>
120-
<Sha>64878fb972e889fc51b1f2e80a1ad2285fbd896c</Sha>
120+
<Sha>b61ece47324607e2ab69de0b6e8cf2d19cef2570</Sha>
121121
</Dependency>
122-
<Dependency Name="Microsoft.DncEng.Configuration.Bootstrap" Version="1.1.0-beta.24555.1">
122+
<Dependency Name="Microsoft.DncEng.Configuration.Bootstrap" Version="1.1.0-beta.24562.1">
123123
<Uri>https://github.com/dotnet/dnceng</Uri>
124-
<Sha>64878fb972e889fc51b1f2e80a1ad2285fbd896c</Sha>
124+
<Sha>b61ece47324607e2ab69de0b6e8cf2d19cef2570</Sha>
125125
</Dependency>
126126
</ToolsetDependencies>
127127
</Dependencies>

eng/Versions.props

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -9,11 +9,11 @@
99
<UsingToolNetFrameworkReferenceAssemblies>true</UsingToolNetFrameworkReferenceAssemblies>
1010
<MicrosoftNetFrameworkReferenceAssembliesVersion>1.0.0-preview.1</MicrosoftNetFrameworkReferenceAssembliesVersion>
1111
<!-- Libs -->
12-
<MicrosoftDotNetSignToolVersion>8.0.0-beta.24525.2</MicrosoftDotNetSignToolVersion>
13-
<MicrosoftDotNetBuildTasksFeedVersion>8.0.0-beta.24525.2</MicrosoftDotNetBuildTasksFeedVersion>
14-
<MicrosoftDotNetSwaggerGeneratorMSBuildVersion>8.0.0-beta.24525.2</MicrosoftDotNetSwaggerGeneratorMSBuildVersion>
15-
<MicrosoftDotNetGitIssueManagerVersion>8.0.0-beta.24525.2</MicrosoftDotNetGitIssueManagerVersion>
16-
<MicrosoftDotNetVersionToolsVersion>8.0.0-beta.24525.2</MicrosoftDotNetVersionToolsVersion>
12+
<MicrosoftDotNetSignToolVersion>8.0.0-beta.24570.5</MicrosoftDotNetSignToolVersion>
13+
<MicrosoftDotNetBuildTasksFeedVersion>8.0.0-beta.24570.5</MicrosoftDotNetBuildTasksFeedVersion>
14+
<MicrosoftDotNetSwaggerGeneratorMSBuildVersion>8.0.0-beta.24570.5</MicrosoftDotNetSwaggerGeneratorMSBuildVersion>
15+
<MicrosoftDotNetGitIssueManagerVersion>8.0.0-beta.24570.5</MicrosoftDotNetGitIssueManagerVersion>
16+
<MicrosoftDotNetVersionToolsVersion>8.0.0-beta.24570.5</MicrosoftDotNetVersionToolsVersion>
1717
<MicrosoftNetTestSdkVersion>17.4.1</MicrosoftNetTestSdkVersion>
1818
<MicrosoftDotNetInternalLoggingVersion>1.1.0-beta.24376.1</MicrosoftDotNetInternalLoggingVersion>
1919
<MicrosoftAspNetCoreApiPaginationVersion>1.1.0-beta.24376.1</MicrosoftAspNetCoreApiPaginationVersion>
@@ -37,8 +37,8 @@
3737
<MicrosoftDotNetWebAuthenticationVersion>1.1.0-beta.24376.1</MicrosoftDotNetWebAuthenticationVersion>
3838
<ServiceFabricMocksVersion>1.1.0-beta.24376.1</ServiceFabricMocksVersion>
3939
<CoreHealthMonitorVersion>1.1.0-beta.24376.1</CoreHealthMonitorVersion>
40-
<MicrosoftDncEngSecretManagerVersion>1.1.0-beta.24555.1</MicrosoftDncEngSecretManagerVersion>
41-
<MicrosoftDncEngConfigurationBootstrapVersion>1.1.0-beta.24555.1</MicrosoftDncEngConfigurationBootstrapVersion>
40+
<MicrosoftDncEngSecretManagerVersion>1.1.0-beta.24562.1</MicrosoftDncEngSecretManagerVersion>
41+
<MicrosoftDncEngConfigurationBootstrapVersion>1.1.0-beta.24562.1</MicrosoftDncEngConfigurationBootstrapVersion>
4242
</PropertyGroup>
4343
<!--Package names-->
4444
<PropertyGroup>

eng/templates/jobs/e2e-pcs-tests.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ jobs:
107107
env:
108108
PCS_BASEURI: ${{ variables.PcsTestEndpoint }}
109109
PCS_TOKEN: $(GetAuthInfo.Token)
110-
GITHUB_TOKEN: $(dotnet-bot-maestro-auth-test-content-rw)
110+
GITHUB_TOKEN: $(dotnet-bot-maestro-auth-test-content-rw-pr-rw)
111111
AZDO_TOKEN: $(AzdoToken)
112112
DARC_PACKAGE_SOURCE: $(Pipeline.Workspace)\PackageArtifacts
113113
DARC_DIR: $(Build.SourcesDirectory)\darc

global.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,6 @@
1515
}
1616
},
1717
"msbuild-sdks": {
18-
"Microsoft.DotNet.Arcade.Sdk": "8.0.0-beta.24525.2"
18+
"Microsoft.DotNet.Arcade.Sdk": "8.0.0-beta.24570.5"
1919
}
2020
}

src/Maestro/Client/src/GlobalSuppressions.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,3 +7,4 @@
77
[assembly: SuppressMessage("Performance", "CA1834:Consider using 'StringBuilder.Append(char)' when applicable", Justification = "Auto-generate code", Scope = "namespaceanddescendants", Target = "~N:Microsoft.DotNet.Maestro.Client")]
88
[assembly: SuppressMessage("Performance", "CA1844:Provide memory-based overrides of async methods when subclassing 'Stream'", Justification = "Auto-generate code", Scope = "namespaceanddescendants", Target = "~N:Microsoft.DotNet.Maestro.Client")]
99
[assembly: SuppressMessage("Style", "IDE0034:Simplify 'default' expression", Justification = "Auto-generate code", Scope = "namespaceanddescendants", Target = "~N:Microsoft.DotNet.Maestro.Client")]
10+
[assembly: SuppressMessage("Style", "IDE0130:Namespace does not match folder structure", Justification = "Auto-generate code", Scope = "namespaceanddescendants", Target = "~N:Microsoft.DotNet.Maestro.Client")]

src/Maestro/DependencyUpdater/DependencyUpdater.cs

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,7 @@
1111
using Maestro.Data;
1212
using Maestro.Data.Models;
1313
using Microsoft.DotNet.DarcLib;
14+
using Microsoft.DotNet.DarcLib.Models.Darc;
1415
using Microsoft.DotNet.Internal.Logging;
1516
using Microsoft.DotNet.ServiceFabric.ServiceHost;
1617
using Microsoft.EntityFrameworkCore;
@@ -296,15 +297,15 @@ public async Task UpdateLongestBuildPathAsync(CancellationToken cancellationToke
296297
};
297298

298299
_logger.LogInformation($"Will update {channel.Name} to best case time {lbp.BestCaseTimeInMinutes} and worst case time {lbp.WorstCaseTimeInMinutes}");
299-
await _context.LongestBuildPaths.AddAsync(lbp);
300+
await _context.LongestBuildPaths.AddAsync(lbp, cancellationToken);
300301
}
301302
else
302303
{
303304
_logger.LogInformation($"Will not update {channel.Name} longest build path because no nodes have {nameof(DependencyFlowNode.OnLongestBuildPath)} flag set. Total node count = {flowGraph.Nodes.Count}");
304305
}
305306
}
306307

307-
await _context.SaveChangesAsync();
308+
await _context.SaveChangesAsync(cancellationToken);
308309
}
309310
}
310311

src/Maestro/FeedCleanerService/FeedCleanerService.cs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,7 @@
1414
using Maestro.Data.Models;
1515
using Microsoft.DotNet.DarcLib;
1616
using Microsoft.DotNet.DarcLib.Helpers;
17+
using Microsoft.DotNet.DarcLib.Models.AzureDevOps;
1718
using Microsoft.DotNet.ServiceFabric.ServiceHost;
1819
using Microsoft.EntityFrameworkCore;
1920
using Microsoft.Extensions.Logging;
@@ -291,7 +292,7 @@ await _azureDevOpsClient.DeleteNuGetPackageVersionFromFeedAsync(feed.Account,
291292
/// <param name="version">Version to search for</param>
292293
/// <param name="packageMappings">Feeds to search</param>
293294
/// <returns>List of feeds in the package mappings where the provided package and version are available</returns>
294-
private List<string> GetReleaseFeedsWherePackageIsAvailable(
295+
private static List<string> GetReleaseFeedsWherePackageIsAvailable(
295296
string name,
296297
string version,
297298
Dictionary<string, Dictionary<string, HashSet<string>>> packageMappings)

src/Maestro/Maestro.Api.Model/v2018_07_16/FlowEdge.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
// The .NET Foundation licenses this file to you under the MIT license.
33

44
using System;
5-
using Microsoft.DotNet.DarcLib;
5+
using Microsoft.DotNet.DarcLib.Models.Darc;
66

77
namespace Maestro.Api.Model.v2018_07_16;
88

src/Maestro/Maestro.Api.Model/v2018_07_16/FlowGraph.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
using System.Collections.Generic;
55
using System.ComponentModel.DataAnnotations;
66
using System.Linq;
7-
using Microsoft.DotNet.DarcLib;
7+
using Microsoft.DotNet.DarcLib.Models.Darc;
88

99
namespace Maestro.Api.Model.v2018_07_16;
1010

src/Maestro/Maestro.Api.Model/v2018_07_16/FlowRef.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
// The .NET Foundation licenses this file to you under the MIT license.
33

44
using System.Collections.Generic;
5-
using Microsoft.DotNet.DarcLib;
5+
using Microsoft.DotNet.DarcLib.Models.Darc;
66
using Newtonsoft.Json;
77

88
namespace Maestro.Api.Model.v2018_07_16;

src/Maestro/Maestro.Api.Model/v2018_07_16/SubscriptionPolicy.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ public SubscriptionPolicy(Data.Models.SubscriptionPolicy other)
2323
UpdateFrequency = (UpdateFrequency)(int)other.UpdateFrequency;
2424
MergePolicies = other.MergePolicies != null
2525
? other.MergePolicies.Select(p => new MergePolicy(p)).ToImmutableList()
26-
: ImmutableList<MergePolicy>.Empty;
26+
: [];
2727
}
2828

2929
public bool Batchable { get; set; } = false;

src/Maestro/Maestro.Api.Model/v2019_01_16/Build.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ public Build(Data.Models.Build other)
5858

5959
public string GitHubBranch { get; set; }
6060

61-
public bool PublishUsingPipelines
61+
public static bool PublishUsingPipelines
6262
{
6363
get
6464
{

src/Maestro/Maestro.Api.Model/v2019_01_16/BuildData.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ public class BuildData
4141

4242
public string GitHubBranch { get; set; }
4343

44-
public bool PublishUsingPipelines
44+
public static bool PublishUsingPipelines
4545
{
4646
get
4747
{

src/Maestro/Maestro.Common/AppCredentials/AppCredential.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ namespace Maestro.Common.AppCredentials;
1111
/// </summary>
1212
public class AppCredential : TokenCredential
1313
{
14-
public static string AUTH_CACHE = Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.UserProfile), ".darc");
14+
public static readonly string AUTH_CACHE = Path.Combine(Environment.GetFolderPath(Environment.SpecialFolder.UserProfile), ".darc");
1515

1616
private static readonly string AUTH_RECORD_PREFIX = ".auth-record";
1717

src/Maestro/Maestro.Data/BuildAssetRegistryContext.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -379,7 +379,7 @@ where buildIds.Contains(build.Id)
379379
b.DateProduced > build.DateProduced);
380380
dict[id].Staleness = newer.Count();
381381
}
382-
return dict.Values.ToList();
382+
return [.. dict.Values];
383383
}
384384

385385
public bool IsProductDependency(

src/Maestro/Maestro.Data/Models/Build.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -136,7 +136,7 @@ public override bool Equals(object obj)
136136

137137
public override int GetHashCode()
138138
{
139-
return (BuildId, ChannelId).GetHashCode();
139+
return HashCode.Combine(BuildId, ChannelId);
140140
}
141141
}
142142

src/Maestro/Maestro.DataProviders/SqlBarClient.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313
using System.Collections.Immutable;
1414
using System.Linq;
1515
using System.Threading.Tasks;
16+
using Microsoft.DotNet.DarcLib.Models.Darc;
1617

1718
namespace Maestro.DataProviders;
1819

src/Maestro/Maestro.MergePolicies/AllChecksSuccessfulMergePolicy.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
using Maestro.Contracts;
99
using Maestro.MergePolicyEvaluation;
1010
using Microsoft.DotNet.DarcLib;
11+
using Microsoft.DotNet.DarcLib.Models;
1112

1213
namespace Maestro.MergePolicies;
1314

src/Maestro/Maestro.MergePolicies/NoRequestedChangesMergePolicy.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
using Maestro.Contracts;
55
using Maestro.MergePolicyEvaluation;
66
using Microsoft.DotNet.DarcLib;
7+
using Microsoft.DotNet.DarcLib.Models;
78
using System.Collections.Generic;
89
using System.Linq;
910
using System.Threading.Tasks;

src/Maestro/Maestro.Web/Api/v2018_07_16/Controllers/ChannelsController.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@
1818
using Channel = Maestro.Api.Model.v2018_07_16.Channel;
1919
using FlowGraph = Maestro.Api.Model.v2018_07_16.FlowGraph;
2020
using ReleasePipeline = Maestro.Api.Model.v2018_07_16.ReleasePipeline;
21+
using Microsoft.DotNet.DarcLib.Models.Darc;
2122

2223
namespace Maestro.Web.Api.v2018_07_16.Controllers;
2324

src/Maestro/Maestro.Web/Api/v2020_02_20/Controllers/BuildsController.cs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@
1818
using Microsoft.Extensions.Internal;
1919
using Newtonsoft.Json.Linq;
2020
using Maestro.Api.Model.v2020_02_20;
21+
using Microsoft.DotNet.DarcLib.Models.Darc;
2122

2223
namespace Maestro.Web.Api.v2020_02_20.Controllers;
2324

src/Maestro/Maestro.Web/BackgroundQueue.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -69,7 +69,7 @@ protected override async Task ExecuteAsync(CancellationToken stoppingToken)
6969
_workItems.CompleteAdding();
7070
}
7171

72-
if (_workItems.TryTake(out (Type type, JToken args) item, 1000))
72+
if (_workItems.TryTake(out (Type type, JToken args) item, 1000, stoppingToken))
7373
{
7474
using (Operation op = _operations.BeginOperation("Executing background work: {item} ({args})", item.type.Name, item.args.ToString(Formatting.None)))
7575
{

src/Maestro/Maestro.Web/Pages/DependencyFlow/Incoming.cshtml.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ namespace Maestro.Web.Pages.DependencyFlow;
2222

2323
public class IncomingModel : PageModel
2424
{
25-
private static readonly Regex _repoParser = new Regex(@"https?://(www\.)?github.com/(?<owner>[A-Za-z0-9-_\.]+)/(?<repo>[A-Za-z0-9-_\.]+)");
25+
private static readonly Regex _repoParser = new(@"https?://(www\.)?github.com/(?<owner>[A-Za-z0-9-_\.]+)/(?<repo>[A-Za-z0-9-_\.]+)");
2626

2727
private readonly BuildAssetRegistryContext _context;
2828
private readonly IGitHubClient _github;
@@ -180,7 +180,7 @@ public string GetBuildUrl(Build? build)
180180
? "(unknown)"
181181
: $"https://dev.azure.com/{build.AzureDevOpsAccount}/{build.AzureDevOpsProject}/_build/results?buildId={build.AzureDevOpsBuildId}&view=results";
182182

183-
private bool IncludeRepo(GitHubInfo? gitHubInfo)
183+
private static bool IncludeRepo(GitHubInfo? gitHubInfo)
184184
{
185185
if (string.Equals(gitHubInfo?.Owner, "dotnet", StringComparison.OrdinalIgnoreCase) &&
186186
string.Equals(gitHubInfo?.Repo, "blazor", StringComparison.OrdinalIgnoreCase))

src/Maestro/Maestro.Web/Startup.cs

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,6 @@
4949
using Microsoft.Extensions.Hosting;
5050
using Microsoft.Extensions.Logging;
5151
using Microsoft.Extensions.Options;
52-
using Microsoft.OpenApi.Models;
5352
using Newtonsoft.Json;
5453
using Newtonsoft.Json.Converters;
5554
using Newtonsoft.Json.Linq;
@@ -293,12 +292,12 @@ public override void ConfigureServices(IServiceCollection services)
293292
(doc, req) =>
294293
{
295294
bool http = HostingEnvironment.IsDevelopment();
296-
doc.Servers = new List<OpenApiServer>
297-
{
295+
doc.Servers =
296+
[
298297
new() {
299298
Url = $"{req.Scheme}://{req.Host.Value}/",
300299
},
301-
};
300+
];
302301

303302
req.HttpContext.Response.Headers["Access-Control-Allow-Origin"] = "*";
304303
});

0 commit comments

Comments
 (0)