Skip to content

Configure OpenTelemetry activity source and service names - #1550

Merged
StefH merged 4 commits into
masterfrom
copilot/add-env-variable-support
Nov 24, 2026
Merged

StefH merged 4 commits into
masterfrom
copilot/add-env-variable-support

Conversation

@StefH

@StefH StefH commented Nov 24, 2026 •

Copy link
Copy Markdown
Collaborator

WireMock instances currently export telemetry under the same name, making them difficult to distinguish. This change adds a configurable name while preserving the default WireMock.Net behavior.

  • Configuration: Add OpenTelemetryOptions.ActivitySourceName, configurable through CLI arguments or environment variables.
  • Instrumentation: Subscribe to both the configured source and WireMock’s built-in source. Use the configured name as the exported service name.
  • Documentation: Describe configuration and update the minimum .NET version to 8.0.

For standalone or Docker deployments:

WireMockServerSettings__OpenTelemetryEnabled=true
WireMockServerSettings__OpenTelemetryActivitySourceName=MyService

Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com>
@StefH StefH changed the title [WIP] Add support for passing ENV variable for Otel Activity Name Configure OpenTelemetry activity source and service names Nov 24, 2026
@StefH StefH added the feature label Nov 24, 2026
Comment thread README.md
* gRPC / ProtoBuf support
* OpenAPI support
* OpenTelemetry support
* [OpenTelemetry support](src/WireMock.Net.OpenTelemetry/README.md), including configurable service names for standalone and Docker instances

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

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

Just keep the link. do not add extra text

@StefH
StefH marked this pull request as ready for review November 24, 2026 18:30
@sonarqubecloud

Copy link
Copy Markdown

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Support for passing ENV variable for Otel Activity Name

2 participants