* Stress test (#3820) * mem leak fix * PR comments fix * PR comments * seems to work? * clang * curl again * add first stress test * also update gitignore * missing line * only linux * clang typo format * typo 2 * PR comments * cspell * remove terminator * Fixed the metadata for better handling (#3824) Co-authored-by: sima-zhu <sizhu@microsoft.com> * Update attestation core vcpkg dependency to latest GA version that is required. (#3830) * Update attestation core vcpkg dependency to latest GA version that is required. * Update vcpkg config.cmake to match the dependency version needed. * Remove winhttp (#3832) * remove refs to winhttp * this tsst only curl * Move perf.yml to eng/common (#3833) Co-authored-by: Mike Harder <mharder@microsoft.com> * Sync eng/common directory with azure-sdk-tools for PR 3656 (#3834) * someone wants to reference the test-proxy startup scripts externally. to make this easy on them we're parameterizing the root of the eng/common for easy use in that scenario * two leading $ signs on the definition of the certificate path was causing some issues! Co-authored-by: scbedd <45376673+scbedd@users.noreply.github.com> * Update casing for 'verison' (#3821) Co-authored-by: Daniel Jurek <djurek@microsoft.com> * Print additional result summary formats to pipelines UI (#3842) Co-authored-by: Mike Harder <mharder@microsoft.com> * Sync eng/common directory with azure-sdk-tools for PR 3702 (#3843) * Add language-service to list of valid sample slugs * Update link to taxonomies Co-authored-by: Heath Stewart <heaths@microsoft.com> * Fix incorrect failure notification in vcpkg publishing (#3838) * Set up for testing of template pipeline * Override branches, set up for template GA release * More TODOs to prevent merging an unintended change * More removal of TestPipeline * Increment template version number * Use script to set package version * Check out the correct branch * branch parameter in the command * Use $(PublishToVcpkg) to determine if we should check for changes * dictionary syntax * Set GA package version to validate GA publish scenario * Update changelog * create-pull-request.yml optionally pushes changes * Output GH PR URI * Macro syntax with a variable set earlier * Move up to 1.2.0-beta.2 * beta.1 * Revert changelog * Revert testing-related changes * Revert vcpkg-clone.yml * Revert eng/common changes, ensure global $(HasChanges) is set properly * Changes to enable testing * 1.1.0-beta.1 * vcpkg clone should clone at configured branch * Clone "main" branch of vcpkg betas * Undo test-specific changes * More PR cleanup * PR cleanup * Helm charts (#3841) * helm chart * first pipe setup * poi * magiks * ewewe * stress * cleanup * pr * QFE and readme * clang * stupid clang , waste of time * ewqwewewrqrewewrqewrqwrqr * stupid clang * cspell * PR * try try again * clang again * Sync eng/common directory with azure-sdk-tools for PR 3661 (#3846) * Add full clone fallback to sparse checkout * Improve clone handling and overrides for sparse checkout * Use SkipSparseCheckout variable name Co-authored-by: Ben Broderick Phillips <bebroder@microsoft.com> * Sync eng/common directory with azure-sdk-tools for PR 3735 (#3845) * Detect API changes using new snadboxinx approach * Added strictmode * Remove unset variable * Changes as per strict mode 3 * Rervert strict mode to allow language level fixes to merge first Co-authored-by: praveenkuttappan <prmarott@microsoft.com> * Increment version for keyvault releases (#3809) * Increment package version after release of azure-security-keyvault-keys * Increment package version after release of azure-security-keyvault-secrets * Increment package version after release of azure-security-keyvault-certificates * Removed hard dependency on opentelemetry version (#3844) * Revert "Add full clone fallback to sparse checkout (#3661)" (#3851) This reverts commit 7605ead00308dd20f20f2afe5acc4ec9900a2c47. Co-authored-by: Ben Broderick Phillips <ben@benbp.net> * Sync eng/common directory with azure-sdk-tools for PR 3753 (#3857) * Bump MacOs version to macos-11 * Update eng/common/scripts/job-matrix/tests/job-matrix-functions.tests.ps1 Co-authored-by: Wes Haggard <weshaggard@users.noreply.github.com> * Update eng/common/scripts/job-matrix/tests/job-matrix-functions.tests.ps1 Co-authored-by: Wes Haggard <weshaggard@users.noreply.github.com> Co-authored-by: sima-zhu <sizhu@microsoft.com> Co-authored-by: Sima Zhu <48036328+sima-zhu@users.noreply.github.com> Co-authored-by: Wes Haggard <weshaggard@users.noreply.github.com> * Bump macOs version to macos-11 (#3853) * Update CHANGELOG.md * Fix misleading step name in az module install (#3859) Co-authored-by: Ben Broderick Phillips <bebroder@microsoft.com> * Retry poll calls on EINTR (#3858) When signals are delievered to the process, calls here to poll may be interrupted and return with a spurious failure. The call instead should be restarted. * Fix bad path to sample matrix json (#3860) Co-authored-by: Ben Broderick Phillips <bebroder@microsoft.com> * Sync eng/common directory with azure-sdk-tools for PR 3826 (#3863) * Add link checking for stress CI * Remove region segment from stress testing links Co-authored-by: Ben Broderick Phillips <bebroder@microsoft.com> * Core August releases (#3862) * Core August releases * cspell Co-authored-by: Anton Kolesnyk <antkmsft@users.noreply.github.com> * Increment version for core releases (#3865) * Increment package version after release of azure-core * Increment package version after release of azure-core-tracing-opentelemetry * Storage Aug GA release (#3864) * CG only runs on internal (#3866) * Condition added and indentation changes * STG 79 80 81 Features (#3850) * Sync eng/common directory with azure-sdk-tools for PR 3860 (#3871) * updating pfx and cert * update the targeted version of the proxy as well Co-authored-by: scbedd <45376673+scbedd@users.noreply.github.com> * Storage August Preview Release (#3868) * Storage August Preview Release * update versions * Increment version for storage releases (#3875) * Increment package version after release of azure-storage-common * Increment package version after release of azure-storage-blobs * Fix an issue that reason phrase is missing as expected from HTTP/2 server (#3879) * Fix an issue that reason phrase is missing as expected from HTTP/2 server * reverse the condition * compact comments * fix clang format * Update CODEOWNERS (#3881) * updated targeted proxy version to one that properly allows consumption of TLS certificates (#3888) Co-authored-by: scbedd <45376673+scbedd@users.noreply.github.com> * Fix `azure-storage-blobs-cpp` beta install (#3889) Co-authored-by: Anton Kolesnyk <antkmsft@users.noreply.github.com> * Fixed #3899 - Handle new OSX version correctly; reformatted platform-matrix JSON files (#3900) * Simpler get-binarysizes check for OSX (#3901) * Simpler get-binarysizes check for OSX * Missed wildcard Co-authored-by: George Arama <50641385+gearama@users.noreply.github.com> Co-authored-by: Azure SDK Bot <53356347+azure-sdk@users.noreply.github.com> Co-authored-by: sima-zhu <sizhu@microsoft.com> Co-authored-by: Ahson Khan <ahson_ahmedk@yahoo.com> Co-authored-by: Mike Harder <mharder@microsoft.com> Co-authored-by: scbedd <45376673+scbedd@users.noreply.github.com> Co-authored-by: Daniel Jurek <djurek@microsoft.com> Co-authored-by: Heath Stewart <heaths@microsoft.com> Co-authored-by: Ben Broderick Phillips <bebroder@microsoft.com> Co-authored-by: praveenkuttappan <prmarott@microsoft.com> Co-authored-by: Ben Broderick Phillips <ben@benbp.net> Co-authored-by: Sima Zhu <48036328+sima-zhu@users.noreply.github.com> Co-authored-by: Wes Haggard <weshaggard@users.noreply.github.com> Co-authored-by: Rick Winter <rick.winter@microsoft.com> Co-authored-by: John Heffner <john@topofcenter.net> Co-authored-by: Anton Kolesnyk <41349689+antkmsft@users.noreply.github.com> Co-authored-by: Anton Kolesnyk <antkmsft@users.noreply.github.com> Co-authored-by: JinmingHu <jinmhu@microsoft.com> Co-authored-by: Jonathan Cárdenas <JonathanCrd@users.noreply.github.com> Co-authored-by: keshen-msft <53491277+keshen-msft@users.noreply.github.com> Co-authored-by: microzchang <110015819+microzchang@users.noreply.github.com>
187 lines
4.3 KiB
PowerShell
187 lines
4.3 KiB
PowerShell
[CmdletBinding()]
|
|
param(
|
|
[Parameter()]
|
|
[string] $BuildDirectory = "$PSScriptRoot/../../build/",
|
|
|
|
[Parameter()]
|
|
[string] $ServiceDirectory = "*",
|
|
|
|
[Parameter()]
|
|
[string] $OsVMImage,
|
|
|
|
[Parameter()]
|
|
[string] $CmakeArgs,
|
|
|
|
[Parameter()]
|
|
[string] $CmakeEnvArg,
|
|
|
|
[Parameter()]
|
|
[string] $BuildArgs,
|
|
|
|
[Parameter()]
|
|
[string] $Job,
|
|
|
|
[Parameter()]
|
|
[string] $BuildReason,
|
|
|
|
[Parameter()]
|
|
[string] $SourceBranch,
|
|
|
|
[Parameter()]
|
|
[switch] $CI = ($null -ne $env:SYSTEM_TEAMPROJECTID),
|
|
|
|
[Parameter()]
|
|
[hashtable]$ExtraLabels = @{}
|
|
)
|
|
|
|
. $PSScriptRoot/../common/scripts/common.ps1
|
|
|
|
function setEnvVar($key, $value) {
|
|
Write-Host "##vso[task.setvariable variable=_$key;issecret=true;]$value"
|
|
}
|
|
|
|
function getTargetOs {
|
|
if ($OsVMImage -like 'macOS*') {
|
|
return $OsVMImage
|
|
}
|
|
|
|
if ($OsVMImage -eq "MMS2019") {
|
|
return "win-2019"
|
|
}
|
|
if ($OsVMImage -eq "windows-2022") {
|
|
return "win-2022"
|
|
}
|
|
|
|
if ($OsVMImage -eq "MMSUbuntu18.04") {
|
|
return "ubuntu-18.04"
|
|
}
|
|
|
|
if ($OsVMImage -eq "MMSUbuntu20.04") {
|
|
return "ubuntu-20.04"
|
|
}
|
|
|
|
LogError "Could not infer target OS from " $OSVmImage
|
|
}
|
|
|
|
function getTargetArchitecture {
|
|
if ($OSVmImage -like 'macOS*') {
|
|
return "x64"
|
|
}
|
|
|
|
if ($env:CMAKE_GENERATOR_PLATFORM -and $env:CMAKE_GENERATOR_PLATFORM -eq "Win32") {
|
|
return "x86"
|
|
}
|
|
|
|
if ($env:CMAKE_GENERATOR_PLATFORM -and $env:CMAKE_GENERATOR_PLATFORM -eq "x64") {
|
|
return "x64"
|
|
}
|
|
|
|
# Most builds target x64 by default
|
|
return "x64"
|
|
}
|
|
|
|
function getToolChain {
|
|
if ($OSVmImage -like 'macOS*') {
|
|
return "AppleClang 12"
|
|
}
|
|
|
|
if ($OSVmImage -eq "MMS2019") {
|
|
return "MSVC"
|
|
}
|
|
|
|
if ($OSVmImage -eq "windows-2022") {
|
|
return "MSVC17"
|
|
}
|
|
|
|
if ($OSVmImage.Contains("Ubuntu")) {
|
|
if ($CmakeEnvArg.Contains('g++-5')) {
|
|
return 'g++-5'
|
|
} elseif ($env:CXX -and $env:CXX.Contains("g++8")) {
|
|
return 'g++-8'
|
|
} elseif ($env:CXX -and $env:CXX.Contains("g++-9")) {
|
|
return 'g++-9'
|
|
} elseif ($env:CXX -and $env:CXX.Contains("clang-11")) {
|
|
return 'clang-11'
|
|
}
|
|
return "g++-7"
|
|
}
|
|
LogError "Could not infer toolchain from " $OSVmImage and $CmakeEnvArg
|
|
}
|
|
|
|
function getTargetPlatform {
|
|
if ($OSVmImage -like 'macOS*') {
|
|
return "macos"
|
|
}
|
|
|
|
if ($OSVmImage -eq 'MMS2019' -or $OsVMImage -eq "windows-2022") {
|
|
if (!$env:CMAKE_SYSTEM_NAME -and !$CmakeArgs.Contains('WindowsStore')) {
|
|
return 'win32'
|
|
} elseif ($env:CMAKE_SYSTEM_NAME -eq 'WindowsStore' -or $CmakeArgs.Contains('WindowsStore')) {
|
|
return 'uwp'
|
|
}
|
|
}
|
|
|
|
if ($OSVmImage.Contains("Ubuntu")) {
|
|
return 'linux'
|
|
}
|
|
|
|
LogError "Could not infer target platform from " $OSVmImage
|
|
}
|
|
|
|
function getBuildConfiguration {
|
|
if ($env:CMAKE_BUILD_TYPE) {
|
|
return $env:CMAKE_BUILD_TYPE
|
|
}
|
|
|
|
if ($BuildArgs.Contains("--config Debug")) {
|
|
return "Debug"
|
|
}
|
|
|
|
if ($BuildArgs.Contains("--config Release")) {
|
|
return "Release"
|
|
}
|
|
|
|
# Most builds default to Debug unless overridden by configuration variables
|
|
return "Debug"
|
|
}
|
|
|
|
$searchPath = "$BuildDirectory/sdk/$ServiceDirectory/*/*.a"
|
|
if ($IsWindows) {
|
|
$searchPath = "$BuildDirectory/sdk/$ServiceDirectory/*/*/*.lib"
|
|
}
|
|
|
|
$binaries = Get-ChildItem -Path $searchPath
|
|
|
|
$buildLabels = @{
|
|
TargetOs = getTargetOs;
|
|
Toolchain = getToolChain;
|
|
BuildConfig = getBuildConfiguration;
|
|
TargetArchitecture = getTargetArchitecture;
|
|
TargetPlatform = getTargetPlatform;
|
|
}
|
|
|
|
if ($CI) {
|
|
foreach ($binary in $binaries) {
|
|
$metricLogObject = @{
|
|
name = "BinarySize";
|
|
value = $binary.Length
|
|
timestamp = (Get-Date -AsUTC).ToString("o")
|
|
labels = @{
|
|
Job = $Job;
|
|
BuildReason = $BuildReason;
|
|
SourceBranch = $SourceBranch;
|
|
BinaryName = $binary.Name;
|
|
} + $buildLabels + $ExtraLabels
|
|
}
|
|
|
|
$metricLogJson = ConvertTo-Json $metricLogObject -Compress
|
|
Write-Host "logmetric: $metricLogJson"
|
|
}
|
|
}
|
|
$binaries `
|
|
| Format-Table -Property Name, @{Name="SizeInKB"; Expression={"{0:N2}" -f ($_.Length / 1KB)}; Alignment='right'} `
|
|
| Out-String `
|
|
| Write-Host
|
|
|
|
return $binaries
|