Skip to main content

Guance OpenTelemetry Python Distro

Project description

pypi

Installation

pip install guance-opentelemetry-distro

This package provides entrypoints to configure OpenTelemetry.

Command Line

The package also installs a gtrace command as a shorthand for auto-instrumented launches:

gtrace uvicorn fastapi-demo:app --host 127.0.0.1 --port 18082

Profiling

The base package installs the guance-sdk-extension-profiling package, which registers an opentelemetry_pre_instrument entry point. Enable it with:

export OTEL_PROFILING_ENABLED=true
gtrace python app.py

When OTEL_PROFILING_PPROF_UPLOAD_URL is configured and OTEL_PROFILING_EXPORTER is unset, profiling defaults to a legacy-compatible pprof upload layout. Explicit OTEL_PROFILING_* settings take precedence.

Common profiling parameters:

  • OTEL_PROFILING_ENABLED

  • OTEL_PROFILING_EXPORTER (otlp or pprof)

  • OTEL_PROFILING_SAMPLE_INTERVAL

  • OTEL_PROFILING_EXPORT_INTERVAL

  • OTEL_PROFILING_MAX_FRAMES

  • OTEL_PROFILING_EXCEPTION_ENABLED

  • OTEL_PROFILING_EXCEPTION_SAMPLING_INTERVAL

  • OTEL_PROFILING_EXCEPTION_COLLECT_MESSAGE

  • OTEL_PROFILING_LOCK_ENABLED

  • OTEL_PROFILING_MEMORY_ENABLED

  • OTEL_PROFILING_MEMORY_INTERVAL

  • OTEL_PROFILING_MEMORY_TOP_STATS

  • OTEL_PROFILING_PPROF_PATH

  • OTEL_PROFILING_PPROF_UPLOAD_URL

  • OTEL_PROFILING_PPROF_HEADERS

  • OTEL_EXPORTER_OTLP_PROFILES_PROTOCOL

  • OTEL_EXPORTER_OTLP_PROFILES_ENDPOINT

  • OTEL_EXPORTER_OTLP_PROFILES_HEADERS

Example:

export OTEL_PROFILING_ENABLED=true
export OTEL_PROFILING_EXCEPTION_ENABLED=true
export OTEL_PROFILING_LOCK_ENABLED=true
export OTEL_PROFILING_MEMORY_ENABLED=true
export OTEL_PROFILING_PPROF_UPLOAD_URL=http://localhost:9529/profiling/v1/input
gtrace python app.py

References

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

guance_opentelemetry_distro-0.63b7.tar.gz (3.4 kB view details)

Uploaded Source

Built Distribution

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

guance_opentelemetry_distro-0.63b7-py3-none-any.whl (4.1 kB view details)

Uploaded Python 3

File details

Details for the file guance_opentelemetry_distro-0.63b7.tar.gz.

File metadata

File hashes

Hashes for guance_opentelemetry_distro-0.63b7.tar.gz
Algorithm Hash digest
SHA256 7acf3483ec273e4f4ab41f62375f24c1a1c94f1413f7658ca418b239aa656230
MD5 1f26ac78e8570c0b28d5cf9128135ea4
BLAKE2b-256 2b353775da7b3badd609a64d02a44424a3e49a1f2c3a1861c7837db27d02ee38

See more details on using hashes here.

File details

Details for the file guance_opentelemetry_distro-0.63b7-py3-none-any.whl.

File metadata

File hashes

Hashes for guance_opentelemetry_distro-0.63b7-py3-none-any.whl
Algorithm Hash digest
SHA256 afaefd5d38be4bd0e76386bf8c28be311e3766196478fb5e87a0d0ec72f34af0
MD5 094178f7ad992c2845b6557358a13152
BLAKE2b-256 2cc47f95c61d48f02f81270145dc0b6f1d11521fc084fe121b625171156febd7

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