PHPackages                             jcchavezs/dd-trace - 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. jcchavezs/dd-trace

Abandoned → [https://github.com/dataDog/dd-trace-php](/?search=https%3A%2F%2Fgithub.com%2FdataDog%2Fdd-trace-php)Library[Logging &amp; Monitoring](/categories/logging)

jcchavezs/dd-trace
==================

DataDog trace library in PHP

0.2.4(9y ago)185733[1 issues](https://github.com/jcchavezs/dd-trace-php/issues)1GPL-3.0PHP

Since Apr 25Pushed 8y ago3 watchersCompare

[ Source](https://github.com/jcchavezs/dd-trace-php)[ Packagist](https://packagist.org/packages/jcchavezs/dd-trace)[ RSS](/packages/jcchavezs-dd-trace/feed)WikiDiscussions master Synced 2w ago

READMEChangelog (1)Dependencies (8)Versions (7)Used By (1)

DataDog Trace PHP
=================

[](#datadog-trace-php)

[![Build Status](https://camo.githubusercontent.com/02e0124c394bc000d307675fdf2436b71ee33c452ac5eccb16d870703864e12f/68747470733a2f2f7472617669732d63692e6f72672f6a6363686176657a732f64642d74726163652d7068702e7376673f6272616e63683d6d6173746572)](https://travis-ci.org/jcchavezs/dd-trace-php)[![Total Downloads](https://camo.githubusercontent.com/c2717080afede229f55d407bb30c338741b34e1a334d028f5a4fda7457171205/68747470733a2f2f706f7365722e707567782e6f72672f6a6363686176657a732f64642d74726163652f646f776e6c6f616473)](https://packagist.org/packages/jcchavezs/dd-trace)[![License](https://camo.githubusercontent.com/073f4e0d7ddcd2cf4816d62823ae21d948540999e63dfc5a78413aa1934bd02a/68747470733a2f2f706f7365722e707567782e6f72672f6a6363686176657a732f64642d74726163652f6c6963656e7365)](https://packagist.org/packages/jcchavezs/dd-trace)

This library contains Datadog's tracing client. It is used to trace requests as they flow across web servers, databases and microservices so that developers have visibility into bottlenecks and troublesome requests.

Tracer has two core objects: Tracers and Spans. Spans represent a chunk of computation time. They have names, durations, timestamps and other metadata. Tracers are used to create hierarchies of spans in a request, buffer and submit them to the server.

The tracing client can perform trace sampling. While the trace agent already samples traces to reduce bandwidth usage, client sampling reduces performance overhead.

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

[](#installation)

DD Trace can be installed by composer:

```
composer require jcchavezs/dd-trace
```

Example
-------

[](#example)

```
use DdTrace\Tracer;
use GuzzleHttp\Exception\RequestException;

$tracer = Tracer::noop();
$client = new GuzzleHttp\Client();

$span = $tracer->createRootSpan("http.client.request", "example.com", "/user/{id}");

$url = "http://example.com/user/123";

try {
    $response = $client->get($url);

    $span->setMeta("http.status", $response->getStatusCode());
    $span->setMeta("http.url", $url);
} catch (RequestException $e) {
    $span->setError($e);
}

$span->finish();
```

Unit testing
------------

[](#unit-testing)

Run in the source folder:

```
make test
```

###  Health Score

31

—

LowBetter than 66% of packages

Maintenance19

Infrequent updates — may be unmaintained

Popularity23

Limited adoption so far

Community15

Small or concentrated contributor base

Maturity57

Maturing project, gaining track record

 Bus Factor1

Top contributor holds 96% 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 ~4 days

Total

6

Last Release

3328d ago

### Community

Maintainers

![](https://www.gravatar.com/avatar/8b5352392ac3b571d5e5d144f6e992040e46726c0863552882cdd8d2577c2eb7?d=identicon)[jcchavezs](/maintainers/jcchavezs)

---

Top Contributors

[![jcchavezs](https://avatars.githubusercontent.com/u/3075074?v=4)](https://github.com/jcchavezs "jcchavezs (24 commits)")[![MDrollette](https://avatars.githubusercontent.com/u/329784?v=4)](https://github.com/MDrollette "MDrollette (1 commits)")

---

Tags

datadogdd-tracedistributed-tracingphptrace

###  Code Quality

TestsPHPUnit

### Embed Badge

![Health badge](/badges/jcchavezs-dd-trace/health.svg)

```
[![Health](https://phpackages.com/badges/jcchavezs-dd-trace/health.svg)](https://phpackages.com/packages/jcchavezs-dd-trace)
```

###  Alternatives

[aws/aws-sdk-php

AWS SDK for PHP - Use Amazon Web Services in your PHP project

6.2k532.1M2.5k](/packages/aws-aws-sdk-php)[tempest/framework

The PHP framework that gets out of your way.

2.2k31.1k12](/packages/tempest-framework)[symfony/symfony

The Symfony PHP framework

31.4k86.9M2.2k](/packages/symfony-symfony)[neuron-core/neuron-ai

The PHP Agentic Framework.

2.0k496.1k33](/packages/neuron-core-neuron-ai)[shopware/core

Shopware platform is the core for all Shopware ecommerce products.

585.4M524](/packages/shopware-core)[theodo-group/llphant

LLPhant is a library to help you build Generative AI applications.

1.7k371.6k6](/packages/theodo-group-llphant)

PHPackages © 2026

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