Skip to content

Add benchmark for beats->protobuf/shipper event conversion#32273

Merged
rdner merged 3 commits intoelastic:mainfrom
rdner:add-shipper-event-conversion-benchmark
Jul 11, 2022
Merged

Add benchmark for beats->protobuf/shipper event conversion#32273
rdner merged 3 commits intoelastic:mainfrom
rdner:add-shipper-event-conversion-benchmark

Conversation

@rdner
Copy link
Copy Markdown
Member

@rdner rdner commented Jul 8, 2022

What does this PR do?

This is to detect future regressions when a change is made to the
conversion function.

Checklist

  • My code follows the style guidelines of this project
  • I have commented my code, particularly in hard-to-understand areas
    - [ ] I have made corresponding changes to the documentation
    - [ ] I have made corresponding change to the default configuration files
    - [ ] I have added tests that prove my fix is effective or that my feature works
    - [ ] I have added an entry in CHANGELOG.next.asciidoc or CHANGELOG-developer.next.asciidoc.

How to test this PR locally

go test -bench=.

Related issues

This is to detect future regressions when a change is made to the
conversion function.
@rdner rdner added the Team:Elastic-Agent-Data-Plane Label for the Agent Data Plane team label Jul 8, 2022
@rdner rdner self-assigned this Jul 8, 2022
@botelastic botelastic bot added needs_team Indicates that the issue/PR needs a Team:* label and removed needs_team Indicates that the issue/PR needs a Team:* label labels Jul 8, 2022
@rdner rdner marked this pull request as ready for review July 8, 2022 14:29
@rdner rdner requested a review from a team as a code owner July 8, 2022 14:29
@rdner rdner requested review from faec and fearful-symmetry and removed request for a team July 8, 2022 14:29
@elasticmachine
Copy link
Copy Markdown
Contributor

Pinging @elastic/elastic-agent-data-plane (Team:Elastic-Agent-Data-Plane)

@rdner rdner requested a review from cmacknz July 8, 2022 14:29
@cmacknz
Copy link
Copy Markdown
Member

cmacknz commented Jul 8, 2022

Out of curiosity what are the benchmark results?

@elasticmachine
Copy link
Copy Markdown
Contributor

elasticmachine commented Jul 8, 2022

💚 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: 2022-07-11T06:55:32.059+0000

  • Duration: 75 min 22 sec

Test stats 🧪

Test Results
Failed 0
Passed 22425
Skipped 1937
Total 24362

💚 Flaky test report

Tests succeeded.

🤖 GitHub comments

To re-run your PR in the CI, just comment with:

  • /test : Re-trigger the build.

  • /package : Generate the packages and run the E2E tests.

  • /beats-tester : Run the installation tests with beats-tester.

  • run elasticsearch-ci/docs : Re-trigger the docs validation. (use unformatted text in the comment!)

@rdner
Copy link
Copy Markdown
Member Author

rdner commented Jul 8, 2022

@cmacknz I don't think it's correct to look at absolute numbers but here is what I have on my
Screenshot 2022-07-08 at 17 02 35

goos: darwin
goarch: arm64
pkg: github.com/elastic/beats/v7/libbeat/outputs/shipper
BenchmarkToShipperEvent-10         38287             30348 ns/op
PASS
ok      github.com/elastic/beats/v7/libbeat/outputs/shipper     3.905s

Copy link
Copy Markdown
Member

@cmacknz cmacknz left a comment

Choose a reason for hiding this comment

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

LGTM, thanks. I might try tweaking the implementation a bit to see if I can get the benchmarks to improve (unless you've already done this). Nothing really jumps out at first glance though.

@rdner rdner merged commit 5154786 into elastic:main Jul 11, 2022
@rdner rdner deleted the add-shipper-event-conversion-benchmark branch July 11, 2022 08:36
chrisberkhout pushed a commit that referenced this pull request Jun 1, 2023
This is to detect future regressions when a change is made to the
conversion function.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Team:Elastic-Agent-Data-Plane Label for the Agent Data Plane team

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Benchmark the shipper output's conversion from publisher.Event

4 participants