Skip to main content

OpenTelemetry Instrumentation for Gunicorn WSGI Server

Project description

OpenTelemetry Instrumentation for Gunicorn

PyPI version Python versions Documentation CI

Automatic OpenTelemetry tracing and metrics for Gunicorn WSGI servers.

Install

pip install opentelemetry-instrumentation-gunicorn opentelemetry-api opentelemetry-sdk

Minimal Usage (Flask)

from flask import Flask
from opentelemetry import trace
from opentelemetry.sdk.trace import TracerProvider
from opentelemetry.sdk.trace.export import BatchSpanProcessor, ConsoleSpanExporter
from opentelemetry.instrumentation.gunicorn import GunicornInstrumentor

trace.set_tracer_provider(TracerProvider())
trace.get_tracer_provider().add_span_processor(BatchSpanProcessor(ConsoleSpanExporter()))

app = Flask(__name__)
GunicornInstrumentor().instrument()

For full examples and guidance, see the docs.

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

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

File details

Details for the file opentelemetry_instrumentation_gunicorn-0.1.0b0.tar.gz.

File metadata

File hashes

Hashes for opentelemetry_instrumentation_gunicorn-0.1.0b0.tar.gz
Algorithm Hash digest
SHA256 a71d310c2ce6c62101dd32fe04213bb606bdefbe13f396dcbc54e1bede6793a6
MD5 17cc82cbdf7f3efa9408d1e232345fb7
BLAKE2b-256 0fd173d747b08db1fbcffb0aea8ef6de4756fd4216a13657cb2e9942bdb542e2

See more details on using hashes here.

File details

Details for the file opentelemetry_instrumentation_gunicorn-0.1.0b0-py3-none-any.whl.

File metadata

File hashes

Hashes for opentelemetry_instrumentation_gunicorn-0.1.0b0-py3-none-any.whl
Algorithm Hash digest
SHA256 6d975c1f342e034f8677383fb38b812b56c2aeae4752cdb81e19cea844a82c16
MD5 6aea9dbc9c6aca3f3dc339cfc6c5dbf9
BLAKE2b-256 b77796327177398ca3eda2b85e9453b72e4f8a5815815c4c542802d115ee66d6

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page