PHPackages                             aaronidas/apm-sql-lexer - 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. aaronidas/apm-sql-lexer

ActiveLibrary

aaronidas/apm-sql-lexer
=======================

SQL Lexer for APM in PHP

v0.0.2(5y ago)379.0k—3.8%2MITPHPPHP &gt;=5.4CI failing

Since Jun 4Pushed 5y ago2 watchersCompare

[ Source](https://github.com/Aaronidas/apm-sql-lexer)[ Packagist](https://packagist.org/packages/aaronidas/apm-sql-lexer)[ RSS](/packages/aaronidas-apm-sql-lexer/feed)WikiDiscussions master Synced 1mo ago

READMEChangelog (2)Dependencies (2)Versions (3)Used By (2)

SQL Lexer for APM agents
========================

[](#sql-lexer-for-apm-agents)

Simple and lightweight parser for span names in APM transactions written in PHP.

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

[](#installation)

Install via \[composer\]

```
composer require aaronidas/apm-sql-lexer
```

How to use
----------

[](#how-to-use)

```
Signature::parse($query);
```

Example:

```
$spanName = Signature::parse('SELECT * FROM foo');
var_dump($spanName);
// output: SELECT FROM foo
```

##### Reference doc for development:

[](#reference-doc-for-development)

[Reference doc](https://docs.google.com/document/d/1sblkAP1NHqk4MtloUta7tXjDuI_l64sT2ZQ_UFHuytA/edit#heading=h.549ltma0zvhu)

- PostgreSQL dollar quoting not implemented yet

###  Health Score

29

—

LowBetter than 59% of packages

Maintenance20

Infrequent updates — may be unmaintained

Popularity34

Limited adoption so far

Community11

Small or concentrated contributor base

Maturity41

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 ~9 days

Total

2

Last Release

2164d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/3e62124e8a85338f374da680e274964b63a519c07461dec9b6e95efbca03dfe6?d=identicon)[Aaronidas](/maintainers/Aaronidas)

---

Top Contributors

[![AaronBernabeu](https://avatars.githubusercontent.com/u/3294776?v=4)](https://github.com/AaronBernabeu "AaronBernabeu (16 commits)")

---

Tags

apm-sql-lexer

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/aaronidas-apm-sql-lexer/health.svg)

```
[![Health](https://phpackages.com/badges/aaronidas-apm-sql-lexer/health.svg)](https://phpackages.com/packages/aaronidas-apm-sql-lexer)
```

PHPackages © 2026

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