Skip to main content
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!

Tool for stream statistics to carbon daemon (from graphite)

Project Description

Tools for serving statistic data to carbon/graphite server.

To install package into django need:

  • add ‘ua2.carbon.middleware.MeasureMiddleware’ at the top of MIDDLEWARE_CLASSES list
  • into settings.py add next lines:
from ua2.carbon.loaders import django_loader
django_loader()

Usage examples

Measure function execution time

from ua2 import carbon

@carbon.measure('myapp')
def test():
        print "Hello World!"

Measure arbitrary block execution time

from ua2 import carbon

def test():
        with carbon.Profiler('myapp'):
                for i in range(1,100):
                        print "Hello World!"

Send raw value to carbon

from ua2 import carbon

def test():
        for i in range(1,100):
                print "Hello World!"
                carbon.send('metric.hello.world', 1)
Release History

Release History

This version
History Node

0.0.4

History Node

0.0.3

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
ua2.carbon-0.0.4.tar.gz (3.7 kB) Copy SHA256 Checksum SHA256 Source Dec 25, 2014

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