aioworkers prometheus integration
Project description
Use
metric:
registry: aioworkers
namespace: aioworkers_test_metric
metrics:
counter:
type: counter
name: test_counter
documentation: Counter for tests
histogram:
type: histogram
name: test_histogram
documentation: Histogram for tests
buckets: [30, 90, 100, 200, 400, 800]
Use in code
context.metric.counter.inc()
context.metric.histogram.observe(542)
with context.metric.histogram.time():
await asyncio.sleep(1)
Serve port 8000 for prometheus
prometheus:
port: 8000
registry: aioworkers
Push to graphite localhost:9090
prometheus:
registry: aioworkers
graphite:
address: localhost:9090
interval: 1m
prefix: aioworkers.test
Development
Install dev requirements:
pipenv install --dev --skip-lock
Run tests:
pipenv run pytest
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
Close
Hashes for aioworkers-prometheus-0.5b3.tar.gz
Algorithm | Hash digest | |
---|---|---|
SHA256 | 981264b97e9a531167ff0d3f22104dcac539b53ace24d23264e5f42e03fb6581 |
|
MD5 | 469f3f3af446db7827c68c4c9eba5366 |
|
BLAKE2b-256 | fc02ce5e32b9d127509167fc0fcdaebcf6d00ed7d92cce654cb5c20a7d689412 |
Close
Hashes for aioworkers_prometheus-0.5b3-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | e959b56b8e83731f20e2cc4c54648bdd2349006cb044942c415a147b99194206 |
|
MD5 | ecd0ac9f6b36318b904192c3e7e262d9 |
|
BLAKE2b-256 | 8c8ca49f86e2d3788894e5961c4f1f8ae871e26d959629e1344033bf10438a30 |