Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add new script to fetch benchmark test-execution-id for baseline and contender #472

Merged
merged 1 commit into from
Aug 6, 2024

Conversation

rishabh6788
Copy link
Collaborator

Description

This PR adds a script to fetch test-execution-id for baseline and contender benchmark runs.
The baseline runs are scheduled to run nightly and have following metadata attached to each metric record, workload, cluster-config and distribution-version and the contender runs have pull_request_number metadata attached to its metrics for easy identification.
The script uses these filters to fetch the latest test-execution-id for baseline and contender runs.
These ids will later be used to run compare command of opensearch-benchmark to fetch comparison results.

Issues Resolved

List any issues this PR will resolve, e.g. Closes [...].

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.
For more information on following Developer Certificate of Origin and signing off your commits, please check here.

}'
"""

println("The curl command is:\n${curlCommand}")
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Shall we remove this since it has risk of exposing the credentials?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Removed, but don't think there is any risk of exposing credentials as jenkins masks all the values since it is used in the scope of withCredentials method.
Have tested and verified this already.

}'
"""

println("The curl command is:\n${curlCommand}")
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same as above.

Comment on lines 108 to 109
String contenderId = processQueryOutput(output)
return contenderId
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit: Can simply return processQueryOutput(output)?


String output = sh(script: curlCommand, returnStdout: true).trim()

String baselineId = processQueryOutput(output)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit: Can simply return processQueryOutput(output)?

…contender

Signed-off-by: Rishabh Singh <sngri@amazon.com>
Copy link

codecov bot commented Aug 6, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 84.29%. Comparing base (7ddabf2) to head (2ba4ca6).

Additional details and impacted files
@@             Coverage Diff              @@
##               main     #472      +/-   ##
============================================
+ Coverage     84.26%   84.29%   +0.03%     
  Complexity       80       80              
============================================
  Files           106      107       +1     
  Lines           521      522       +1     
  Branches         61       61              
============================================
+ Hits            439      440       +1     
  Misses           26       26              
  Partials         56       56              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@peterzhuamazon
Copy link
Member

Please make sure to rerun the autobump workflow after closing the old one.
So that this new file can properly change the version.

Thanks.

@rishabh6788
Copy link
Collaborator Author

Yes, I am waiting on a few PRs from @OVI3D0 for the same.
Will merge them and then do version bump.

@rishabh6788 rishabh6788 merged commit f482df7 into opensearch-project:main Aug 6, 2024
9 checks passed
opensearch-trigger-bot bot pushed a commit that referenced this pull request Aug 6, 2024
…contender (#472)

Signed-off-by: Rishabh Singh <sngri@amazon.com>
(cherry picked from commit f482df7)
Signed-off-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
Status: ✅ Done
Development

Successfully merging this pull request may close these issues.

2 participants