Skip to main content

Quick and easy monitoring setup for ASGI application

Project description

asgi-monitor logo

PyPI version Documentation Status Test Supported versions Downloads License

A library for easy and fast configuration of logging, tracing and metrics for ASGI applications.

Features:

[!IMPORTANT] At this stage, the library is being tested and be careful in using it, your participation in the development will be appreciated!

📚 Documentation

Installation

pip install asgi-monitor

Quickstart

from asgi_monitor.integrations.fastapi import setup_metrics, MetricsConfig
from fastapi import FastAPI
from uvicorn import run


def run_app() -> None:
   app = FastAPI()
   setup_metrics(app, MetricsConfig(app_name="fastapi"))
   run(app, host="127.0.0.1", port=8000)


if __name__ == "__main__":
   run_app()

After setting up, you can see visualization of default metrics in Grafana

Dashboard

The library originates from structlog-asgi

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

asgi-monitor-0.4.0.tar.gz (16.0 kB view hashes)

Uploaded Source

Built Distribution

asgi_monitor-0.4.0-py3-none-any.whl (23.5 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