#2130 Add a performance monitoring framework and initial test
Merged by pingou. Opened by puiterwijk.
puiterwijk/pagure perf  into  master

Download 2130.patch

This is a framework that allows testing for the number of times we walk over a git repository while processing a specific request.
This allows us to start testing for the number of git repository actions, since those constitute the majority of Pagure performance costs.

For verbose information while debugging, one can run the runserver as:

PAGURE_PERFREPO=true PAGURE_PERFREPO_VERBOSE=true ./runserver.py

This will print the collected performance statistics at the end of every request.

rebased

Should we put like a warning of something, maybe just a comment about what number we should aim for?

rebased

rebased

rebased

rebased

3 new commits added

  • Add performance totals plugin
  • Add performance checks to the test suite
  • Add performance repo analyzer

Idea: could we adjust runserver so that it has a parameter to turn on PAGURE_PERFREPO=true PAGURE_PERFREPO_VERBOSE=true directly? (as we do with -c/--config)

'counters': {'diffs': 0, 'walks': 8}, should this include the inits as well?

PERFORMANCE TOTALS:, should we be more explicit about what performances we're talking about? (pygit2 performance, git performance?)

Otherwise, it's looking really quite neat :)

rebased

Thanks! :)

Pull-Request has been merged by pingou

Metadata