From 0d7e0c60259f573fb5eeb584b500fb997d16f4c2 Mon Sep 17 00:00:00 2001 From: Drew Scoggins Date: Mon, 13 Sep 2021 16:50:26 -0700 Subject: [PATCH 1/2] Change channel passed to ci_setup to track runtime branch With this change we move to specifing the channel that is passed to ci_setup, instead of it always being main. The allows us to have the runtime branch help decide the correct version of the sdk that we should pull down with dotnet-install. This means that going forward, we will need to have channels that match the names of all branches that we plan to run from the runtime side. If we do not, the sdk installation step will fail during ci_setup. --- eng/testing/performance/performance-setup.ps1 | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/eng/testing/performance/performance-setup.ps1 b/eng/testing/performance/performance-setup.ps1 index 9ed93d17fbd829..16563a87cc93e5 100644 --- a/eng/testing/performance/performance-setup.ps1 +++ b/eng/testing/performance/performance-setup.ps1 @@ -97,7 +97,8 @@ if ($iOSMono) { } # FIX ME: This is a workaround until we get this from the actual pipeline -$CommonSetupArguments="--channel main --queue $Queue --build-number $BuildNumber --build-configs $Configurations --architecture $Architecture" +$CleanedBranchName = $Branch.replace('refs/heads/', '') +$CommonSetupArguments="--channel $CleanedBranchName --queue $Queue --build-number $BuildNumber --build-configs $Configurations --architecture $Architecture" $SetupArguments = "--repository https://github.com/$Repository --branch $Branch --get-perf-hash --commit-sha $CommitSha $CommonSetupArguments" if($NoPGO) From 32f8f3f7e400765aa8ce56d11e25fe26f21f3a31 Mon Sep 17 00:00:00 2001 From: Drew Scoggins Date: Mon, 20 Sep 2021 09:48:44 -0700 Subject: [PATCH 2/2] Change logic to not break private runs The previous change here broke private runs as it required the channel map to have an entry matching the name of the runtime branch you were testing. This fix now defaults the channel to main for private runs. --- eng/testing/performance/performance-setup.ps1 | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/eng/testing/performance/performance-setup.ps1 b/eng/testing/performance/performance-setup.ps1 index 16563a87cc93e5..ae30e9bac80ead 100644 --- a/eng/testing/performance/performance-setup.ps1 +++ b/eng/testing/performance/performance-setup.ps1 @@ -97,7 +97,11 @@ if ($iOSMono) { } # FIX ME: This is a workaround until we get this from the actual pipeline -$CleanedBranchName = $Branch.replace('refs/heads/', '') +$CleanedBranchName = "main" +if($Branch.Contains("refs/heads/release")) +{ + $CleanedBranchName = $Branch.replace('refs/heads/', '') +} $CommonSetupArguments="--channel $CleanedBranchName --queue $Queue --build-number $BuildNumber --build-configs $Configurations --architecture $Architecture" $SetupArguments = "--repository https://github.com/$Repository --branch $Branch --get-perf-hash --commit-sha $CommitSha $CommonSetupArguments"