3tears-observe


توضیحات

Structured logging, tracing, and OpenTelemetry setup for 3tears applications
ویژگی مقدار
سیستم عامل -
نام فایل 3tears-observe-0.89.0
نام 3tears-observe
نسخه کتابخانه 0.89.0
نگهدارنده []
ایمیل نگهدارنده []
نویسنده pace
ایمیل نویسنده -
آدرس صفحه اصلی -
آدرس اینترنتی https://pypi.org/project/3tears-observe/
مجوز -
# 3tears-observe Structured logging, tracing, and OpenTelemetry setup for 3tears applications. ## Modules - `threetears.observe.logging` -- Structured logging with context correlation and automatic call-site capture. - `threetears.observe.tracing` -- `@traced` decorator (zero-cost without OpenTelemetry). - `threetears.observe.metrics` -- `counter`/`histogram`/`gauge` get-or-create accessors plus the `@metered` decorator built on them, records prometheus metrics (zero-cost without prometheus_client). - `threetears.observe.setup` -- OpenTelemetry SDK bootstrap (TracerProvider, LoggerProvider, OTLP exporters). ## Installation ```bash pip install 3tears-observe # With OpenTelemetry SDK support, traces over OTLP/gRPC: pip install 3tears-observe[otel] # The same over OTLP/HTTP, with no gRPC installed (about 10 MB against about 49): pip install 3tears-observe[otel-http] ``` With `otel-http`, set `TelemetryConfig(protocol="http/protobuf", endpoint="http://collector:4318")`; spans go to `<endpoint>/v1/traces`. `protocol` defaults to `"grpc"`, which needs the `otel` extra. Log export is OTLP/HTTP under either extra.


نیازمندی

مقدار نام
xtr uuid-utils;
xtr opentelemetry-api<2,>=1.40;
xtr opentelemetry-exporter-otlp-proto-grpc<2,>=1.40;
xtr opentelemetry-exporter-otlp-proto-http<2,>=1.40;
xtr opentelemetry-instrumentation-logging<1,>=0.61b0;
xtr opentelemetry-instrumentation<1,>=0.61b0;
xtr opentelemetry-sdk<2,>=1.40;
xtr opentelemetry-api<2,>=1.40;
xtr opentelemetry-exporter-otlp-proto-http<2,>=1.40;
xtr opentelemetry-instrumentation-logging<1,>=0.61b0;
xtr opentelemetry-instrumentation<1,>=0.61b0;
xtr opentelemetry-sdk<2,>=1.40;
xtr prometheus-client>=0.20;


زبان مورد نیاز

مقدار نام
>=3.14 Python


نحوه نصب


نصب پکیج whl 3tears-observe-0.89.0:

    pip install 3tears-observe.whl


نصب پکیج tar.gz 3tears-observe-0.89.0:

    pip install 3tears-observe.tar.gz