PHPackages                             xolegator/pinba\_extension - 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. [Logging &amp; Monitoring](/categories/logging)
4. /
5. xolegator/pinba\_extension

ActivePhp-ext[Logging &amp; Monitoring](/categories/logging)

xolegator/pinba\_extension
==========================

Pinba PHP extension: collects request and timer metrics and ships them over UDP (protobuf) to Pinba Engine.

00C

Since Jun 13Pushed todayCompare

[ Source](https://github.com/XOlegator/pinba_extension)[ Packagist](https://packagist.org/packages/xolegator/pinba_extension)[ RSS](/packages/xolegator-pinba-extension/feed)WikiDiscussions master Synced today

READMEChangelog (6)DependenciesVersions (1)Used By (0)

Pinba Extension (Modernization Fork)
====================================

[](#pinba-extension-modernization-fork)

[![CI](https://github.com/XOlegator/pinba_extension/actions/workflows/ci.yml/badge.svg)](https://github.com/XOlegator/pinba_extension/actions/workflows/ci.yml)[![Lint](https://github.com/XOlegator/pinba_extension/actions/workflows/lint.yml/badge.svg)](https://github.com/XOlegator/pinba_extension/actions/workflows/lint.yml)[![codecov](https://camo.githubusercontent.com/8b009ec9eb8987f70d8f947651ea7ca4ebb2bca83797bdd623aa18d1a3063efc/68747470733a2f2f636f6465636f762e696f2f67682f584f6c656761746f722f70696e62615f657874656e73696f6e2f6272616e63682f6d61737465722f67726170682f62616467652e737667)](https://codecov.io/gh/XOlegator/pinba_extension)[![Release](https://camo.githubusercontent.com/ed55dcd3397f885b29ca88a2fbff5c0bef75d67eb551705ee1b75e3efb8ef7a6/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f762f72656c656173652f584f6c656761746f722f70696e62615f657874656e73696f6e)](https://github.com/XOlegator/pinba_extension/releases/latest)[![Packagist](https://camo.githubusercontent.com/9ec742c7e6062c108033c49a167d43ae23385850dc1244eb80d24b3e56e6c936/68747470733a2f2f696d672e736869656c64732e696f2f7061636b61676973742f762f786f6c656761746f722f70696e62615f657874656e73696f6e3f6c6f676f3d7061636b6167697374266c6f676f436f6c6f723d7768697465)](https://packagist.org/packages/xolegator/pinba_extension)[![PHP](https://camo.githubusercontent.com/aab105773946948a51b291cd97af724b06e81a249f8be9d5f978173259442ba6/68747470733a2f2f696d672e736869656c64732e696f2f62616467652f5048502d382e32253230253743253230382e33253230253743253230382e34253230253743253230382e352d3737374242343f6c6f676f3d706870266c6f676f436f6c6f723d7768697465)](https://github.com/XOlegator/pinba_extension/blob/master/.github/php-versions.json)[![License: LGPL-2.1](https://camo.githubusercontent.com/454f5d8187a0f5fbf10bad13e418635d8f5f72f4875394701aa58ae08f7e0ccc/68747470733a2f2f696d672e736869656c64732e696f2f6769746875622f6c6963656e73652f584f6c656761746f722f70696e62615f657874656e73696f6e)](https://github.com/XOlegator/pinba_extension/blob/master/COPYING)

Pinba Extension is the PHP client extension for the Pinba monitoring stack. It collects timing and request metrics inside PHP, serializes them with protobuf, and sends them over UDP to Pinba Engine.

This repository is an actively maintained fork of the original project:

- Original project: [tony2001/pinba\_extension](https://github.com/tony2001/pinba_extension)
- Active fork: [XOlegator/pinba\_extension](https://github.com/XOlegator/pinba_extension)

Where This Project Fits
-----------------------

[](#where-this-project-fits)

 ```
flowchart LR
    app[PHP application]
    ext[pinba_extension]
    engine[Pinba Engine plugin]
    mysql[(MySQL)]
    pinboard[Pinboard]

    app -->|request shutdown metrics| ext
    ext -->|UDP protobuf packets| engine
    engine --- mysql
    pinboard -->|SQL queries and dashboards| mysql
```

      Loading Short version:

- `pinba_extension` lives inside PHP applications and produces runtime metrics.
- `pinba_engine` receives those metrics over UDP and exposes them through MySQL tables.
- `pinboard` reads aggregated and raw data from MySQL and presents it to users.

Fork Goals
----------

[](#fork-goals)

The purpose of this fork is to take over active development and make the extension usable on modern systems again.

Current development direction:

- support modern PHP versions and current Zend APIs;
- replace obsolete build and test workflows with reproducible automation;
- add CI for build, lint, tests, and packaging;
- add Debian and Launchpad packaging for supported Ubuntu releases;
- automate rebuilds when new supported PHP versions appear;
- preserve wire compatibility with the existing Pinba protocol and ecosystem.

Installation
------------

[](#installation)

### From the PPA (Ubuntu, recommended)

[](#from-the-ppa-ubuntu-recommended)

Prebuilt packages are published to the [`ppa:xolegator/packages`](https://launchpad.net/~xolegator/+archive/ubuntu/packages) Launchpad PPA:

```
sudo add-apt-repository ppa:xolegator/packages
sudo apt-get update
sudo apt-get install php8.5-pinba   # also available: php8.4-pinba, php8.3-pinba, php8.2-pinba
```

Availability per Ubuntu release: 24.04 `noble` ships `php8.2`–`php8.5`; 26.04 `resolute` ships `php8.5`.

The package installs the extension and enables it (`phpenmod`). Set the runtime options in a drop-in such as `/etc/php//mods-available/pinba.ini` (or a separate `conf.d` file), then reload the SAPI:

```
pinba.enabled = 1
pinba.server  = 127.0.0.1:30002
```

```
sudo systemctl restart php8.5-fpm   # for FPM; CLI picks the new config up automatically
```

### From source

[](#from-source)

```
phpize
./configure --enable-pinba
make -j"$(nproc)"
sudo make install
```

This requires the matching `php-dev` and `libprotobuf-c-dev` packages. See [docs/build.md](docs/build.md) for the full local build and test flow.

### Docker and other distributions

[](#docker-and-other-distributions)

Outside Debian/Ubuntu the extension is built from source against the system protobuf-c runtime. Install the build toolchain and the protobuf-c development headers for your platform:

- Debian / Ubuntu: `libprotobuf-c-dev`
- Fedora / RHEL: `protobuf-c-devel`
- Alpine: `protobuf-c-dev`

**Docker (official PHP images)** — build and enable the extension in your image:

```
FROM php:8.5-fpm

RUN apt-get update \
 && apt-get install -y --no-install-recommends $PHPIZE_DEPS git libprotobuf-c-dev \
 && git clone --depth 1 https://github.com/XOlegator/pinba_extension.git /usr/src/pinba \
 && cd /usr/src/pinba \
 && phpize && ./configure --enable-pinba && make -j"$(nproc)" && make install \
 && docker-php-ext-enable pinba \
 && rm -rf /usr/src/pinba /var/lib/apt/lists/*

RUN printf "pinba.enabled=1\npinba.server=pinba-engine:30002\n" \
      > "$PHP_INI_DIR/conf.d/zz-pinba.ini"
```

`$PHPIZE_DEPS` and `$PHP_INI_DIR` are provided by the official `php` images. For a slimmer image you may `apt-get purge $PHPIZE_DEPS` afterwards, but keep the runtime `libprotobuf-c1`.

**PIE (PHP Installer for Extensions)** — this repository ships [PIE](https://github.com/php/pie)metadata (`composer.json` with `"type": "php-ext"`) and is published to [Packagist](https://packagist.org/packages/xolegator/pinba_extension), so the extension can be installed cross-platform with:

```
pie install xolegator/pinba_extension
```

PIE still compiles from source, so it needs the same build toolchain and `libprotobuf-c` headers as a manual source build.

Development Baseline
--------------------

[](#development-baseline)

The active CI matrix builds the extension and runs the PHPT suite on `PHP 8.2`, `8.3`, `8.4`, and `8.5`, and enforces workflow, shell, and markdown linting plus `clang-format` and `clang-tidy` in GitHub Actions. The PHP matrix source of truth is `.github/php-versions.json`, and scheduled discovery automation refreshes it through PRs. Build-from-source steps are covered under [Installation](#from-source) and [docs/build.md](docs/build.md).

Documentation
-------------

[](#documentation)

- Development workflow and branch/commit rules: [docs/development.md](docs/development.md)
- Local build and test workflow: [docs/build.md](docs/build.md)
- Packaging direction and package naming: [docs/packaging.md](docs/packaging.md)
- Supported platforms and lifecycle policy: [docs/support-matrix.md](docs/support-matrix.md)
- Release process and automatic changelog flow: [docs/releasing.md](docs/releasing.md)
- Historical legacy release notes (curated): [docs/legacy-news.md](docs/legacy-news.md)
- Verbatim upstream `NEWS` archive: [docs/legacy-upstream-news.md](docs/legacy-upstream-news.md)
- Contribution guide: [CONTRIBUTING.md](CONTRIBUTING.md)
- Security policy: [SECURITY.md](SECURITY.md)
- Support policy: [SUPPORT.md](SUPPORT.md)
- Shared Pinba knowledge base: [XOlegator/pinba\_engine/knowledge](https://github.com/XOlegator/pinba_engine/tree/master/knowledge)

Release Process
---------------

[](#release-process)

This fork uses a semi-automated GitHub release flow:

- regular work is merged to `master` through Pull Requests;
- PR titles and commits must follow Conventional Commits;
- accepted changes are accumulated into `CHANGELOG.md` automatically;
- release PRs, version bumps, tags, and GitHub Releases are managed by automation.

Historical upstream notes remain in `docs/legacy-news.md` and `docs/legacy-upstream-news.md`; all new fork release history belongs in `CHANGELOG.md`.

License
-------

[](#license)

This fork inherits the original project license and remains available under the [GNU Lesser General Public License v2.1 or later](LICENSE).

Copyright:

- 2009-2013 Antony Dovgal
- 2026-present Oleg Ekhlakov

Provenance and third-party dependency notices are documented in [NOTICE](NOTICE), and project authorship in [AUTHORS](AUTHORS).

###  Health Score

20

—

LowBetter than 13% of packages

Maintenance65

Regular maintenance activity

Popularity0

Limited adoption so far

Community2

Small or concentrated contributor base

Maturity11

Early-stage or recently created project

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.

### Community

Maintainers

![](https://avatars.githubusercontent.com/u/2227351?v=4)[Oleg Ekhlakov](/maintainers/XOlegator)[@XOlegator](https://github.com/XOlegator)

### Embed Badge

![Health badge](/badges/xolegator-pinba-extension/health.svg)

```
[![Health](https://phpackages.com/badges/xolegator-pinba-extension/health.svg)](https://phpackages.com/packages/xolegator-pinba-extension)
```

###  Alternatives

[psr/log

Common interface for logging libraries

10.4k1.2B10.8k](/packages/psr-log)[open-telemetry/api

API for OpenTelemetry PHP.

1938.5M260](/packages/open-telemetry-api)[open-telemetry/sdk

SDK for OpenTelemetry PHP.

2326.5M315](/packages/open-telemetry-sdk)[illuminated/console-logger

Logging and Notifications for Laravel Console Commands.

8676.7k](/packages/illuminated-console-logger)

PHPackages © 2026

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