Skip to main content

WSGI Middleware version of the CherryPy memory leak debugger

Project description

Dozer

Dozer was originally a WSGI middleware version of Robert Brewer’s Dowser CherryPy tool that displays information as collected by the gc module to assist in tracking down memory leaks. It now also has middleware for profiling and for looking at logged messages.

Tracking down memory leaks

Usage:

from dozer import Dozer

# my_wsgi_app is a WSGI application
wsgi_app = Dozer(my_wsgi_app)

Assuming you’re serving your application on the localhost at port 5000, you can then load up http://localhost:5000/_dozer/index to view the gc info.

Profiling requests

Usage:

from dozer import Profiler

# my_wsgi_app is a WSGI application
wsgi_app = Profiler(my_wsgi_app)

Assuming you’re serving your application on the localhost at port 5000, you can then load up http://localhost:5000/_profiler to view the list of recorded request profiles.

Here’s a blog post by Marius Gedminas that contains a longer description of Dozer’s profiler.

Inspecting log messages

Usage:

from dozer import Logview

# my_wsgi_app is a WSGI application
wsgi_app = Logview(my_wsgi_app)

Every text/html page served by your application will get some HTML and Javascript injected into the response body listing all logging messages produced by the thread that generated this response.

Here’s a blog post by Marius Gedminas that contains a longer description of Dozer’s logview.

Dozer Changelog

0.3.1 (February 6, 2013)

0.3 (December 13, 2012)

  • Emit the “PIL is not installed” only if the Dozer middleware is actually used.

  • Give a name to the Dozer memleak thread.

  • You can now supply a function directly to Logview(stack_formatter=fn)

  • New configuration option for Logview middleware: tb_formatter, similar to stack_formatter, but for exception tracebacks.

0.2 (December 5, 2012)

  • Adding logview that appends log events for the current request to the bottom of the html output for html requests.

  • Adding profiler for request profiling and call tree viewing.

  • Refactored Dozer into its own leak package.

  • New maintainer: Marius Gedminas.

0.1 (June 14, 2008)

  • Initial public release, port from Dowser, a CherryPy tool.

Project details


Download files

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

Source Distribution

Dozer-0.3.1.tar.gz (73.8 kB view details)

Uploaded Source

File details

Details for the file Dozer-0.3.1.tar.gz.

File metadata

  • Download URL: Dozer-0.3.1.tar.gz
  • Upload date:
  • Size: 73.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No

File hashes

Hashes for Dozer-0.3.1.tar.gz
Algorithm Hash digest
SHA256 70502de9519b01aa7bdd0e4db7c5e190880fb82809d06a7608b009adb543340c
MD5 389da13970bdf577bfde48fe17750a60
BLAKE2b-256 f75c7ea24ecfa50cba2114632fef96a5dd83dc8e7f355ecbce88ae294a73ad9a

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page