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

Migration to buildkite #135

Merged
merged 23 commits into from
Jul 10, 2023
Merged

Migration to buildkite #135

merged 23 commits into from
Jul 10, 2023

Conversation

leo-ri
Copy link
Contributor

@leo-ri leo-ri commented Jun 19, 2023

No description provided.

@elasticmachine
Copy link
Collaborator

elasticmachine commented Jun 19, 2023

💚 Build Succeeded

the below badges are clickable and redirect to their specific view in the CI or DOCS
Pipeline View Test View Changes Artifacts preview preview

Expand to view the summary

Build stats

  • Start Time: 2023-07-07T16:27:06.503+0000

  • Duration: 4 min 19 sec

Test stats 🧪

Test Results
Failed 0
Passed 397
Skipped 40
Total 437

@elasticmachine
Copy link
Collaborator

elasticmachine commented Jun 19, 2023

📚 Go benchmark report

Diff with the main branch

goos: linux
goarch: amd64
pkg: github.com/elastic/go-libaudit/v2/aucoalesce
cpu: Intel(R) Xeon(R) CPU @ 2.30GHz
                   │ build/main/bench.out │             bench.out              │
                   │        sec/op        │    sec/op     vs base              │
CoalesceMessages-8           5.979µ ± ∞ ¹   5.897µ ± ∞ ¹  -1.37% (p=0.016 n=5)
¹ need >= 6 samples for confidence interval at level 0.95

                   │ build/main/bench.out │           bench.out            │
                   │         B/op         │     B/op       vs base         │
¹ need >= 6 samples for confidence interval at level 0.95

                   │ build/main/bench.out │           bench.out            │
                   │      allocs/op       │  allocs/op   vs base           │
¹ need >= 6 samples for confidence interval at level 0.95
² all samples are equal

pkg: github.com/elastic/go-libaudit/v2/auparse
                                     │ build/main/bench.out │             bench.out              │
                                     │        sec/op        │    sec/op     vs base              │
ExtractKeyValuePairs/short_message-8           2.478µ ± ∞ ¹   2.538µ ± ∞ ¹  +2.42% (p=0.032 n=5)
ParseAuditHeaderRegex-8                        869.7n ± ∞ ¹   897.1n ± ∞ ¹  +3.15% (p=0.008 n=5)
ParseLogLine-8                                 338.3n ± ∞ ¹   351.3n ± ∞ ¹  +3.84% (p=0.008 n=5)
geomean                                        2.788µ         2.894µ        +3.77%
¹ need >= 6 samples for confidence interval at level 0.95

                                     │ build/main/bench.out │               bench.out               │
                                     │         B/op         │     B/op       vs base                │
geomean                                                   ³                  +0.09%               ³
¹ need >= 6 samples for confidence interval at level 0.95
² all samples are equal
³ summaries must be >0 to compute geomean

                                     │ build/main/bench.out │              bench.out              │
                                     │      allocs/op       │  allocs/op   vs base                │
geomean                                                   ³                +0.00%               ³
¹ need >= 6 samples for confidence interval at level 0.95
² all samples are equal
³ summaries must be >0 to compute geomean

report generated with https://pkg.go.dev/golang.org/x/perf/cmd/benchstat

@jlind23
Copy link
Collaborator

jlind23 commented Jun 20, 2023

@cachedout while migrating this repo we discovered that benchmarks results are pushed to a central bucket. Are you using this results for any kind of automation?

@jlind23 jlind23 marked this pull request as ready for review June 30, 2023 14:26
@jlind23 jlind23 requested review from alexsapran and mrodm July 3, 2023 16:08
@@ -0,0 +1,60 @@
#!/usr/bin/env bash
set -euxo pipefail
Copy link
Contributor

Choose a reason for hiding this comment

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

Could this script launch .ci/test.sh, it looks like this script is doing more or less the same as that other file.

Or maybe, could we use that script directly as a command in the step definition ?

set +e
list="$(go list ./... | grep -v /vendor/)"
list_string="${list//$'\n'/ }"
if [[ $root == "true" ]]; then
Copy link
Contributor

Choose a reason for hiding this comment

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

Where is it needed root ? In .ci/test.sh, it looks like it is not needed root.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

These tests are indeed running by non-root user in Jenkins, and the current builkite agent has user root inside the container, as a result, the different groups of tests will be running in these two cases. For making it the same, I changed a little bit the script (partially related to all comments)

- label: ":linux: Microbench"
key: benchmark
command:
- ".buildkite/scripts/bench.sh"
Copy link
Contributor

Choose a reason for hiding this comment

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

Maybe we can keep the same shellscript under .ci to be used in .buildkite.
In this case, here it could be directly used that file:

Suggested change
- ".buildkite/scripts/bench.sh"
- ".ci/bench.sh"

WDYT ? @leo-ri @alexsapran

@leo-ri leo-ri requested a review from mrodm July 4, 2023 15:47
.buildkite/pipeline.yml Outdated Show resolved Hide resolved
@leo-ri leo-ri requested a review from mrodm July 5, 2023 15:16
Copy link
Contributor

@mrodm mrodm left a comment

Choose a reason for hiding this comment

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

Checking Jenkins pipeline, in that pipeline it is added comments in PRs for every pull request:

notifyBuildResult(prComment: true, goBenchmarkComment: true)

Should we add it now also in Buildkite ?
This is an example from elastic-package
https://github.com/elastic/elastic-package/blob/604c606c86bea611975fa9c9722a30a44b2204fb/catalog-info.yaml#L56-L57

@jlind23
Copy link
Collaborator

jlind23 commented Jul 5, 2023

@mrodm @alexsapran don't you think we can remove the Jenkinsfile at the same time here?

@jlind23
Copy link
Collaborator

jlind23 commented Jul 8, 2023

@leo-ri don't you think the .ci folder can be completely removed?

@leo-ri
Copy link
Contributor Author

leo-ri commented Jul 10, 2023

@leo-ri don't you think the .ci folder can be completely removed?

discussed in person

@jlind23 jlind23 merged commit 9956fe8 into elastic:main Jul 10, 2023
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants