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

Performance testing #173

Open
1 of 3 tasks
elementbound opened this issue Dec 12, 2023 · 0 comments
Open
1 of 3 tasks

Performance testing #173

elementbound opened this issue Dec 12, 2023 · 0 comments

Comments

@elementbound
Copy link
Contributor

elementbound commented Dec 12, 2023

Background

There's plans to explore options to improve netfox's performance. But to do that, we first need a method to measure the current performance, and be able to compare new methods against it. Ideally, this measurement is automated and requires as little human intervention as possible.

Metrics

  • Bandwidth
    • Sent bandwidth - min, max, avg, one second windows
    • Received bandwidth - min, max, avg, one second windows
    • See EnetConnection.pop_statistic
  • CPU usage
    • Network tick loop duration
    • Rollback tick loop duration
    • Network ticks per loop
    • Rollback ticks per loop
    • Can be done with custom monitors

Implementation steps

  • Perf test game
    • Game tries to host, otherwise connect
    • Address and port can be set from command line, defaults to localhost
    • Each client acts as a bot, wandering around randomly
  • Implement NetfoxPerformance - feat: Performance monitors #195
    • Activate only in debug builds or if manually activated
    • Subscribes to netfox events and manages custom monitors
  • Configure perf test build
    • Can use feature flag to differentiate
    • Runs perf test game for a given duration
    • Outputs perf data at end
    • Implement black box class to track and output perf test data
  • ?? Configure perf testing GitHub action

Notes

  • Why not pre-recorded inputs for Forest Brawl?
    • Pros: realistic traffic, as it's an actual game
    • Cons: doesn't scale well to arbitrary amount of players?
elementbound added a commit that referenced this issue Jan 30, 2024
Implements NetworkPerformance autoload, that provides custom monitors
for networking performance measurements.

Refs #173
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
1 participant