PHPackages                             kinetis/telemetry - PHPackages - PHPackages  [Skip to content](#main-content)[PHPackages](/)[Directory](/)[Categories](/categories)[Trending](/trending)[Leaderboard](/leaderboard)[Changelog](/changelog)[Analyze](/analyze)[Collections](/collections)[Log in](/login)[Sign up](/register)

1. [Directory](/)
2. /
3. kinetis/telemetry

ActiveLibrary

kinetis/telemetry
=================

OpenTelemetry tracing for Kinetis — request spans, SQL and queue decorators, a traced HTTP transport, and OTLP export over the Revolt-backed client.

v1.3.0(yesterday)03↓50%MITPHPPHP ^8.4

Since Aug 16Pushed yesterdayCompare

[ Source](https://github.com/kinetis-dev/telemetry)[ Packagist](https://packagist.org/packages/kinetis/telemetry)[ RSS](/packages/kinetis-telemetry/feed)WikiDiscussions main Synced today

READMEChangelogDependencies (15)Versions (6)Used By (0)

 [![Kinetis](logo.svg)](logo.svg)

 **kinetis/telemetry**
 **OpenTelemetry tracing for Kinetis**

 [![Packagist Version](https://camo.githubusercontent.com/61c3ae33f7555d1fc25794a1c07fcc24279922e982060bf4bfdfebee3a0b4598/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f6b696e657469732f74656c656d657472793f6c6162656c3d76657273696f6e)](https://packagist.org/packages/kinetis/telemetry) [![Packagist Downloads](https://camo.githubusercontent.com/35483a6de0d6a2bdfc8cd81a77ef7f2d703a5a4007cf589e23638f449df81a33/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f64742f6b696e657469732f74656c656d65747279)](https://packagist.org/packages/kinetis/telemetry) [![PHP Version](https://camo.githubusercontent.com/85e83bb0332f4ef6bc46bcea41210efcf6d79936818bf562c489d06e2af482cd/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f7068702d762f6b696e657469732f74656c656d65747279)](https://packagist.org/packages/kinetis/telemetry) [![License](https://camo.githubusercontent.com/3d834581b6cd4af0779a8fd101c3c4d85c4d1b70dd304c3f0d583bd791bb1d45/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f6c2f6b696e657469732f74656c656d65747279)](https://packagist.org/packages/kinetis/telemetry) [![CI](https://github.com/kinetis-dev/kinetis/actions/workflows/ci.yml/badge.svg)](https://github.com/kinetis-dev/kinetis/actions/workflows/ci.yml)

---

A span per request, per SQL query, per queue job, and per outgoing HTTP call, exported over OTLP to any tracing backend. Export goes through `kinetis/revolt-http-client`'s Fiber-suspending transport, so flushing a span batch never blocks the worker.

The distinctive trace this produces: spans that *overlap in time*. A request running two queries and an HTTP call through `concurrently()`shows all three side by side inside the request span — what non-blocking I/O actually did for that request, visible.

Set one environment variable and requests start tracing:

```
OTEL_EXPORTER_OTLP_ENDPOINT=http://jaeger:4318
```

Provides
--------

[](#provides)

Installing this package auto-registers, via `extra.kinetis`:

- **Global middleware** `RequestSpanMiddleware` — one server span per request (method, `url.path`, status, `php.memory.usage`; an incoming `traceparent` joins the caller's trace).
- **A container binding** for `OpenTelemetry\API\Trace\TracerProviderInterface` — the OTLP-exporting provider when `OTEL_EXPORTER_OTLP_ENDPOINT` is set, a no-op provider otherwise, so an unconfigured install costs near nothing.
- **The framework's instrumentation hooks, turned on** — when the OTLP endpoint is set, the bootstrap swaps an OTel backend into core's `Kinetis\Instrumentation\Telemetry` holder, so the spans the framework reports from inside itself (boot phases, per-middleware timing, route match, hydration, controller, queries split at the pool boundary, transactions, `concurrently()` tasks, events, MCP calls, queue jobs) start exporting with no further wiring.

Nothing else. The decorators below are explicit opt-ins wired in your own `bootstrap.php`.

Decorators
----------

[](#decorators)

- `TracingMysqlLink` / `TracingPostgresLink` — a span per SQL query (named by first keyword, full SQL as `db.query.text`, parameter values never recorded), wrapping any `kinetis/persistence` link while keeping its dialect marker. Transactions they begin span `COMMIT` and `ROLLBACK` too.
- `TracingQueue` — a producer span per `push()`; a consumer span from `pop()` to `ack()`/`release()`/`fail()` carrying the outcome, active while the job runs so its own queries and HTTP calls nest under it.
- `TracingHttpClient` — a client span per outgoing request with `traceparent` injection, ending when the response is consumed rather than when `request()` returns. Hand it to `Http` as its transport.
- `TraceAwareLogger` — wraps any PSR-3 logger, adding the active span's `trace_id`/`span_id` to every entry's context.

Configuration
-------------

[](#configuration)

KeyDefaultPurpose`OTEL_EXPORTER_OTLP_ENDPOINT`—Collector's OTLP/HTTP base URL. Unset = tracing off (no-op provider).`OTEL_SERVICE_NAME``kinetis`The `service.name` resource attribute.`OTEL_EXPORTER_OTLP_HEADERS`—Export headers, `key=value,key2=value2` — a hosted backend's auth.`OTEL_TRACES_SAMPLER``parentbased_always_on`Standard sampler names; `traceidratio` + `OTEL_TRACES_SAMPLER_ARG` for a rate.`OTEL_TRACES_SAMPLER_ARG``1.0`Ratio for the `traceidratio` samplers, `0`–`1`.Installation
------------

[](#installation)

```
composer require kinetis/telemetry
```

Requires PHP 8.4+. Full documentation: [docs.kinetis.dev/telemetry.html](https://docs.kinetis.dev/telemetry.html).

License
-------

[](#license)

MIT — see [LICENSE](../../LICENSE).

###  Health Score

43

—

FairBetter than 89% of packages

Maintenance100

Actively maintained with recent releases

Popularity4

Limited adoption so far

Community6

Small or concentrated contributor base

Maturity54

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 100% of commits — single point of failure

How is this calculated?**Maintenance (25%)** — Last commit recency, latest release date, and issue-to-star ratio. Uses a 2-year decay window.

**Popularity (30%)** — Total and monthly downloads, GitHub stars, and forks. Logarithmic scaling prevents top-heavy scores.

**Community (15%)** — Contributors, dependents, forks, watchers, and maintainers. Measures real ecosystem engagement.

**Maturity (30%)** — Project age, version count, PHP version support, and release stability.

###  Release Activity

Cadence

Every ~0 days

Total

5

Last Release

1d ago

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/17613001?v=4)[aln-1](/maintainers/aln-1)[@aln-1](https://github.com/aln-1)

---

Top Contributors

[![86208620](https://avatars.githubusercontent.com/u/288746?v=4)](https://github.com/86208620 "86208620 (5 commits)")

###  Code Quality

TestsPHPUnit

Static AnalysisPHPStan, Psalm

Type Coverage Yes

### Embed Badge

![Health badge](/badges/kinetis-telemetry/health.svg)

```
[![Health](https://phpackages.com/badges/kinetis-telemetry/health.svg)](https://phpackages.com/packages/kinetis-telemetry)
```

###  Alternatives

[shopware/core

Shopware platform is the core for all Shopware ecommerce products.

595.8M672](/packages/shopware-core)[shopware/platform

The Shopware e-commerce core

3.4k1.5M3](/packages/shopware-platform)[sulu/sulu

Core framework that implements the functionality of the Sulu content management system

1.3k1.4M236](/packages/sulu-sulu)[contao/core-bundle

Contao Open Source CMS

1301.7M3.1k](/packages/contao-core-bundle)[bitrix24/b24phpsdk

An official PHP library for the Bitrix24 REST API

10250.3k6](/packages/bitrix24-b24phpsdk)[contao/contao

Contao Open Source CMS development package

43514.5k2](/packages/contao-contao)

PHPackages © 2026

[Directory](/)[Categories](/categories)[Trending](/trending)[Changelog](/changelog)[Analyze](/analyze)
