Skip to main content

Flask-Statsd

Generate and send Flask metrics in Graphite Carbon Format format.

Install

pip install flask-carbon-statsd

# Latest Code

pip install git+https://github.com/labeneator/flask_carbon_statsd.git

Usage Example

# myapp.py
from flask import Flask, Blueprint
from flask_carbon_statsd import FlaskCarbonStatsdTimerCounter

flask_metrics = FlaskCarbonStatsdTimerCounter(host='localhost', port=8125)


app = Flask(__name__)
flask_metrics.init_app(app)

# or
flask_metrics = FlaskCarbonStatsd(app=app, host='localhost', port=8125)

bp = Blueprint('dashboard', __name__)

@bp.route('/dashboard')
def index(device):
    return 'OK'

app.register_blueprint(bp)
  • Request /dashboard with FlaskCarbonStatsdTimer

    flask.carbon.statsd.dev.flask_template.app.local.LocalHost-3.dashboard.index.200:3.650904|ms
    
  • Request /dashboard with FlaskCarbonStatsdTimerCounter

    flask.carbon.statsd.dev.flask_template.app.local.LocalHost-3.dashboard.index.200:3.650904|ms
    flask.carbon.statsd.dev.flask_template.app.local.LocalHost-3.dashboard.index.200:1|c
    

Release files for flask-carbon-statsd 0.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for flask-carbon-statsd 0.1
File Size Uploaded
flask-carbon-statsd-0.1.tar.gz 3.2 kB Details

Release files / flask-carbon-statsd-0.1.tar.gz

Download URL flask-carbon-statsd-0.1.tar.gz
Size 3.2 kB
Tags Source
SHA-256 checksum
How to use checksums
67a7f8831eed0e1124646db1cc599bf36cdbd2d80e304515e7a0c292e690a97f
BLAKE2b-256 checksum
How to use checksums
a164e7c5df8645e0c112cc505cf1147a825ac11642e6a906f8d95706f86e85f5
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/1.13.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/40.8.0 requests-toolbelt/0.9.1 tqdm/4.35.0 CPython/3.7.4

Release history Release notifications | RSS feed

This release

0.1 This release

1 release file

0.0.1

1 release file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page