Skip to main content

An asyncio-based client for sending metrics to StatsD with support of DogStatsD extension

Project description

aiodogstatsd

An asyncio-based client for sending metrics to StatsD with support of DogStatsD extension.

Library fully tested with statsd_exporter and supports gauge, counter, histogram, distribution and timing types.

Installation

$ pip install aiodogstatsd

Usage

import asyncio

import aiodogstatsd


async def main():
    client = aiodogstatsd.Client()
    await client.connect()

    client.increment("users.online")

    await client.close()


asyncio.run(main())

Look at examples/ to find more examples of library usage.

Contributing

To work on the aiodogstatsd codebase, you'll want to clone the project locally and install the required dependencies via poetry:

$ git clone git@github.com:Gr1N/aiodogstatsd.git
$ poetry install

To run tests and linters use command below:

$ poetry run tox

If you want to run only tests or linters you can explicitly specify which test environment you want to run, e.g.:

$ poetry run tox -e py37-tests

License

aiodogstatsd is licensed under the MIT license. See the license file for details.

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

aiodogstatsd-0.1.0.tar.gz (5.0 kB view hashes)

Uploaded Source

Built Distribution

aiodogstatsd-0.1.0-py3-none-any.whl (12.1 kB view hashes)

Uploaded Python 3

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