ruby-grape / grape

An opinionated framework for creating REST-like APIs in Ruby.
http://www.ruby-grape.org
MIT License
9.86k stars 1.22k forks source link

Add a memory usage check #2442

Open dblock opened 2 months ago

dblock commented 2 months ago

Coming from #2440 and #2441 and similar leaks that we've had in the past, add a tool that compares memory usage before/after a change in pull requests. This could be modeled after https://code.dblock.org/2024/04/19/commenting-on-pull-requests-in-github-actions.html (newer version in https://github.com/opensearch-project/opensearch-api-specification/pull/297).

  1. Create a benchmark that causes a lot of memory allocations quickly.
  2. In every PR run the benchmark on the before code and the after code, generate some data on allocations.
  3. Add a comment to the PR showing the change.