Simple Django middleware for submitting timings and exceptions to Datadog.
Project description
# Django Datadog
A simple Django middleware for submitting timings and exceptions to Datadog.
## Installation
Download the code into your project and install it.
`bash git clone git://github.com/conorbranagan/django-datadog.git cd django-datadog python setup.py install `
Add datadog to your list of installed apps.
`python INSTALLED_APPS += ('datadog') `
Add the following configuration to your projects’ settings.py file:
`python DATADOG_API_KEY = 'YOUR_API_KEY' DATADOG_APP_KEY = 'YOUR_APP_KEY' DATADOG_APP_NAME = 'my_app' # Used to namespace metric names `
The API and app keys can be found at https://app.datadoghq.com/account/settings#api
Add the Datadog request handler to your middleware in settings.py.
`python MIDDLEWARE_CLASSES += ('datadog.middleware.DatadogMiddleware') `
## Usage
Once the middlewhere installed, you’ll start receiving events in your Datadog stream in the case of an app exception. Here’s an example:
![example django exception](https://dl.dropbox.com/u/126553/django-datadog.png)
You will also have new timing metrics available:
my_app.request_time.{avg,max,min}
my_app.errors
Metrics are tagged with path:/path/to/view
Note: my_app will be replaced by whatever value you give for DATADOG_APP_NAME.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Hashes for avk-django-datadog-0.1.0.6.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 5987787306a6843270731d0a05ba6884a21e15084c797f0e3b53c558f5aee604 |
|
MD5 | b1a4facbcab05c5f23088e215362c33b |
|
BLAKE2b-256 | 53176625dce9943ea9737ce99ae6410a457de30ba59a5c49fec6dd83c40bde07 |
Hashes for avk_django_datadog-0.1.0.6-py2-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 973f3cc338891fd26a847afdacda1be13226daf3168e676bb540f28db27b2abd |
|
MD5 | 1758e99593e5eec5408f6d14ee1c81ca |
|
BLAKE2b-256 | 9e38eaf3255741a4ed873259f03131096b0a8a1ed8aea610a912d365a5ce2f93 |