Skip to content

Conversation

@prateek-kumar-improving
Copy link
Collaborator

@prateek-kumar-improving prateek-kumar-improving commented Nov 7, 2025

Issue link

This Pull Request is linked to issue (URL): valkey-io/valkey-glide#4588

Description

The PHP client provides a complete OpenTelemetry integration for distributed tracing and observability of Valkey operations.

Key Features:
Static API: Simple static methods on ValkeyGlide and ValkeyGlideCluster classes
Sampling Control: Configurable percentage-based sampling (0-100%)
Manual Span Management: Create and end spans for custom tracing
Process-Level Initialization: Initialize once per PHP process

Files Created:
• valkey_glide_otel.h - Header definitions
• valkey_glide_otel.c - Core implementation
• ValkeyGlideFeaturesTest.php, ValkeyGlideClusterFeaturesTest.php and tests/TestValkeyGlide.php - Tests
• Config classes.

Files Modified:
• valkey_glide.stub.php & valkey_glide_cluster.stub.php - Added method signatures
• valkey_glide.c and valkey_glide_cluster.c
• config.m4 - Build system integration
• package.xml - PECL distribution manifest

Checklist

Before submitting the PR make sure the following are checked:

  • This Pull Request is related to one issue.
  • Commit message has a detailed description of what changed and why.
  • Tests are added or updated.
  • CHANGELOG.md and documentation files are updated.
  • Destination branch is correct - main or release
  • Create merge commit if merging release branch into main, squash otherwise.

Signed-off-by: Prateek Kumar <[email protected]>
@prateek-kumar-improving prateek-kumar-improving added the php Pull requests that update php code label Nov 7, 2025
Signed-off-by: Prateek Kumar <[email protected]>
Signed-off-by: Prateek Kumar <[email protected]>
Signed-off-by: Prateek Kumar <[email protected]>
Signed-off-by: Prateek Kumar <[email protected]>
Signed-off-by: Prateek Kumar <[email protected]>
Signed-off-by: Prateek Kumar <[email protected]>
Signed-off-by: Prateek Kumar <[email protected]>
Signed-off-by: Prateek Kumar <[email protected]>
…yConfigBuilder.php and OpenTelemetryConfig.php

Signed-off-by: Prateek Kumar <[email protected]>
Copy link
Collaborator

@currantw currantw left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks @prateek-kumar-improving.
Approved ✅

@yipin-chen yipin-chen merged commit 864edaf into main Nov 25, 2025
25 of 26 checks passed
@yipin-chen yipin-chen deleted the php/add-otel branch November 25, 2025 23:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

php Pull requests that update php code

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants