This is a pre-production deployment of Warehouse. Changes made here affect the production instance of PyPI (pypi.python.org).
Help us improve Python packaging - Donate today!

"Profiler for buildbot master and its UI"

Project Description

This plugin implements a profiler for buildbot master.

  • It uses statistical profiling loosely based on plop https://github.com/bdarnell/plop
  • Suitable for prod as statistical profiling is very low overhead
  • Profiles all threads including main thread and db threads
  • Removes noise samples when the threads are actually in the main loop
  • In-browser UI based on nvd3 and d3-flame-graph
  • Show cpu and memory percent over time
  • flame graph can be restricted to a subset of the trace
  • Detailed caller/callee are displayed when clicking on a function

Usage

installation:

pip install buildbot_profiler

then in master.cfg:

c['www']['plugins']['profiler'] = True

Alternatively, you can install it in service mode, without the UI

c['services'] = [util.ProfilerService()]

ProfilerService takes following arguments:

ProfilerService(frequency=100, gatherperiod=30 * 60, mode='virtual', basepath=None, wantBuilds=100)
  • frequency: the profiling frequency in HZ. Not that if there is no activity during a profiling timer, no data will be recorded.

  • gatherperiod: the period during which the profiler works on one file. By default a new json file is created every 30min with the profile of the last 30min. Note that if there is no activity the gather period might be longer.

  • mode: profiling timer to use. Can be:

    • prof: use SIG_PROF timer,
    • virtual: use SIGVTALRM timer,
    • real: use SIGALRM timer,
  • basepath: the base path where to store the json files. (defaults to (master's basedir)/prof_)

  • wantBuilds: if this is > 0 then the last N builds are stored along side the profile data, for debug purpose.

Standalone Viewer

A standalone viewer is provided for offline browse of user submitted profiles.

bbprofiler

Then you can open your browser on http://localhost:8080

Screenshot

Release History

Release History

This version
History Node

1.1.1

History Node

1.1.0

History Node

1.0.0

History Node

0.0.2

History Node

0.0.1

Download Files

Download Files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

File Name & Checksum SHA256 Checksum Help Version File Type Upload Date
buildbot_profiler-1.1.1-py2.py3-none-any.whl (848.8 kB) Copy SHA256 Checksum SHA256 py2.py3 Wheel Jul 23, 2017
buildbot-profiler-1.1.1.tar.gz (810.1 kB) Copy SHA256 Checksum SHA256 Source Jul 23, 2017

Supported By

WebFaction WebFaction Technical Writing Elastic Elastic Search Pingdom Pingdom Monitoring Dyn Dyn DNS Sentry Sentry Error Logging CloudAMQP CloudAMQP RabbitMQ Heroku Heroku PaaS Kabu Creative Kabu Creative UX & Design Fastly Fastly CDN DigiCert DigiCert EV Certificate Rackspace Rackspace Cloud Servers DreamHost DreamHost Log Hosting