Skip to main content

A Django middleware that logs tracebacks of slow requests.

Project description

Overview

Dogslow is Django watchdog middleware class that logs tracebacks of slow requests.

Installation

Install dogslow:

$ pip install dogslow

Then add if to your list of middleware classes in your Django settings.py file:

MIDDLEWARE_CLASSES = (
    'dogslow.WatchdogMiddleware',
    ...
)

For best results, make it one of the first middlewares that is run.

Configuration

You can use the following configuration properties in your settings.py file to tune the watchdog:

# Watchdog is enabled by default, to temporarily disable, set to False:
DOGSLOW = True

# Location where Watchdog stores its log files:
DOGSLOW_OUTPUT = '/tmp'

# Log requests taking longer than 25 seconds:
DOGSLOW_TIMER = 25

# When both specified, emails backtraces:
DOGSLOW_EMAIL_TO = 'errors@atlassian.com'
DOGSLOW_EMAIL_FROM = 'no-reply@atlassian.com'

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

dogslow-0.1.tar.gz (13.4 kB view hashes)

Uploaded Source

Supported by

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