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

Tooling to benchmark wire messages #120

Open
wants to merge 11 commits into
base: main
Choose a base branch
from

Conversation

rockdaboot
Copy link
Contributor

@rockdaboot rockdaboot commented Aug 15, 2024

This PR is a PoC/RFC for #110.

The PR adds three new options to the profiling agent

  • -reporter-record-inputs-to=<FILE> to record all internal data passed to the reporter into the given NDJSON file.
  • -reporter-replay-inputs-from=<FILE> replays the data from the given NDJSON file.
  • -reporter-save-outputs-to=<DIR> records all wire messages uncompressed into the given directory, one file per message.

The PR also adds tools/protobench that allows compressing the wire messages recorded by the profiling agent with different compression algorithms and levels. The compressors are all imported as Go dependencies (external tools are not used), as that is what the profiling agent would use. The results can be output as CSV or as PNG file (bar chart).

This should combine with prior work from @petethepig (see https://docs.google.com/spreadsheets/d/1Q-6MlegV8xLYdz5WD5iPxQU2tsfodX1-CDV1WeGzyQ0/edit?gid=1732807979#gid=1732807979)

Copy link
Contributor

@athre0z athre0z left a comment

Choose a reason for hiding this comment

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

Looks promising -- added a few comments!

cli_flags.go Outdated Show resolved Hide resolved
tools/protobench/cli_flags.go Show resolved Hide resolved
reporter/benchmark.go Outdated Show resolved Hide resolved
reporter/benchmark.go Outdated Show resolved Hide resolved
tools/protobench/README.md Outdated Show resolved Hide resolved
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.

2 participants