Download the PHP package open-telemetry/opentelemetry-sqlcommenter without Composer
On this page you can find all versions of the php package open-telemetry/opentelemetry-sqlcommenter. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.
Download open-telemetry/opentelemetry-sqlcommenter
More information about open-telemetry/opentelemetry-sqlcommenter
Files in open-telemetry/opentelemetry-sqlcommenter
Package opentelemetry-sqlcommenter
Short Description OpenTelemetry sqlcommenter.
License Apache-2.0
Homepage https://opentelemetry.io/docs/languages/php/
Informations about the package opentelemetry-sqlcommenter
Note: This is a read-only subtree split of open-telemetry/opentelemetry-php-contrib.
OpenTelemetry SQL Commenter
OpenTelemetry SQL Commenter for PHP provides a SqlCommenter implementation, enabling you to inject trace and context comments into SQL queries for enhanced observability and distributed tracing.
Installation
Install via Composer:
Usage
Inject comments into your SQL query as follows:
Configuration
-
Context Propagators
Set the propagators to use (comma-separated):
Default:
'' -
SQL Commenter Attribute
Add SQL comments to
DbAttributes::DB_QUERY_TEXTin span attributes:or via environment variable:
Default:
false -
Prepend Comments
Prepend comments to the query statement using either a configuration directive:
or via environment variable:
Default:
false
Development
Install dependencies and run tests from the SqlCommenter subdirectory: