Skip to content

Commit

Permalink
Sync eng/common directory with azure-sdk-tools for PR 4878 (Azure#32452)
Browse files Browse the repository at this point in the history
* Pass profile flag

* Fix conditional add of '--profile'

* One more attempt at how to enable profile

* Don't publish everything

* Move profile parameter after iterations

* Pass profile parameter as flag option

* Create profile variable

Co-authored-by: Alan Zimmer <48699787+alzimmermsft@users.noreply.github.com>
Co-authored-by: Mike Harder <mharder@microsoft.com>
  • Loading branch information
3 people authored Dec 5, 2022
1 parent 664833d commit a33b77f
Showing 1 changed file with 15 additions and 0 deletions.
15 changes: 15 additions & 0 deletions eng/common/pipelines/templates/jobs/perf.yml
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,9 @@ parameters:
- name: Iterations
type: number
default: '5'
- name: Profile
type: boolean
default: false
- name: AdditionalArguments
type: string
default: ''
Expand All @@ -77,6 +80,11 @@ jobs:
MatrixName: 'Windows'
variables:
- ${{ parameters.Variables }}
- name: Profile
${{ if parameters.Profile }}:
value: '--profile'
${{ else }}:
value: ''
pool:
name: $(Pool)
vmImage: $(OSVmImage)
Expand Down Expand Up @@ -125,6 +133,7 @@ jobs:
--tests "${{ parameters.Tests }}"
--arguments "${{ parameters.Arguments }}"
--iterations ${{ parameters.Iterations }}
$(Profile)
${{ parameters.AdditionalArguments }}
workingDirectory: azure-sdk-tools/tools/perf-automation/Azure.Sdk.Tools.PerfAutomation
env:
Expand Down Expand Up @@ -162,6 +171,12 @@ jobs:
artifactName: results-${{ parameters.Language }}-$(MatrixName)
condition: always()

- task: PublishPipelineArtifact@1
inputs:
targetPath: $(System.DefaultWorkingDirectory)/${{ parameters.Language }}-profile.zip
artifactName: ${{ parameters.Language }}-profile.zip
condition: ${{ parameters.Profile }}

- template: /eng/common/TestResources/remove-test-resources.yml
parameters:
ServiceDirectory: ${{ parameters.ServiceDirectory }}
Expand Down

0 comments on commit a33b77f

Please sign in to comment.