open-telemetry/sdk
OpenTelemetry PHP SDK for generating and exporting traces, metrics, and logs. Use with compatible exporters and configure via code or environment variables. Supports Composer autoload-based SDK initialization and global tracer/meter providers.
Http facade).Baggage for request IDs).Span::recordException()) for GDPR/SOC2 traceability.OTEL_PHP_AUTOLOAD_ENABLED (zero-cost in production if unused).Adopt if:
Span::setAttribute('user.id', ...)).Look elsewhere if:
For Executives: "OpenTelemetry’s PHP SDK lets us standardize observability across our stack—reducing tooling costs by 40% while improving incident response time. For example, we’ll auto-instrument Laravel’s HTTP layer to detect slow third-party API calls (e.g., Stripe, Twilio) without code changes. This aligns with our 2024 SRE goals and avoids vendor lock-in with proprietary APMs."
For Engineering: *"This gives us:
OTEL_PHP_AUTOLOAD_ENABLED.Illuminate\Support\Facades\Http, Log, and Queue out of the box.AlwaysRecordSampler in dev, then optimize."*For DevOps:
"We can replace custom log parsers with structured telemetry (e.g., Span::setAttribute('cart.value', 99.99)), cutting alert noise. Exporters like OtlpHttpExporter let us send data to existing backends (e.g., Grafana Tempo) without new infrastructure."
How can I help you explore Laravel packages today?