Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(publish-metrics): run otel tracing for vendor specific reporters #2418

Conversation

InesNi
Copy link
Contributor

@InesNi InesNi commented Jan 16, 2024

Description

Integrating the OTel reporter with existing vendor-specific reporters in order to streamline the process for users to send traces to their chosen observability platforms.

Context

OTel reporter provides certain tracing capabilities and features that are not available through original vendor specific reporters, e.g. the support for the Playwright engine.
However, users might not get to experience this due to the following reasons:

  • Finding the exact information needed to configure OTel reporter can be challenging for users especially if they have not worked with OpenTelemetry before.
  • They might not realise that it is possible to use OTel reporter to send data to their chosen platform

Objective

The aim of this PR is to streamline the process for users to send traces to their chosen observability platforms by integrating the OTel reporter with existing vendor-specific reporters.

Implementation

To accomplish this integration, the vendor specific reporters configuration will additionally be passed to the OTel reporter, which will then translate the configuration in the OTel reporter format and run the tracing as per usual.

This way the basic configuration for the user would stay the same with additional settings for the new capabilities.

In this PR OTel tracing is integrated into the following reporters:

  • Honeycomb
  • Datadog
  • New Relic
  • Dynatrace

Configuration

Honeycomb

  plugins:
    publish-metrics:
      - type: honeycomb
        dataset: dataset_name
        apiKey: "{{ $env.HC_API_KEY }}"
        sampleRate: 0.5
        useRequestNames: true
        attributes:
          tool: "artillery"
        smartSampling:
          thresholds:
            firstByte: 500
            total: 2000

Datadog

  plugins:
    publish-metrics:
      - type: datadog
        sendOnlyTraces: true
        traces: 
          sampleRate: 0.5
          useRequestNames: true
          tags:
            "tool:artillery"
          smartSampling:
            thresholds:
              firstByte: 500
              total: 2000

New Relic

  plugins:
    publish-metrics:
      - type: newrelic
         licenseKey: "{{ $env.LICENSE_KEY }}"
         sendOnlyTraces: true
         traces: 
           serviceName: service_name
           sampleRate: 0.5
           useRequestNames: true
           attributes:
             tool: "artillery"
           smartSampling:
             thresholds:
               firstByte: 500
               total: 2000

Dynatrace

  plugins:
    publish-metrics:
      - type: dynatrace
         apiToken: "{{ $env.DYNATRACE_API_TOKEN }}"
         envUrl: "{{ $env.DYNATRACE_URL }}"
         sendOnlyTraces: true
         traces: 
           serviceName: service_name
           sampleRate: 0.5
           useRequestNames: true
           attributes:
             tool: "artillery"
           smartSampling:
             thresholds:
               firstByte: 500
               total: 2000
  • sendOnlyTraces is added to all reporters except for Honeycomb as they all send metrics by default, this option enables users to send only traces if they wish to.
  • All other additional configuration has been added within the new traces block, except in Honeycomb. The Honeycomb reporter was since beginning just for traces so no need to nest the settings in traces block

Notes

  • This PR will restrict the number of reporters used for sending traces in a single test to 1, making this a breaking change. Multiple reporters will still be able to be set for metrics, as long as there is only one reporter set for tracing.

Pre-merge checklist

  • Does this require an update to the docs?
  • Does this require a changelog entry?

@InesNi InesNi marked this pull request as ready for review January 19, 2024 13:51
@InesNi InesNi requested a review from a team January 19, 2024 16:09
@InesNi InesNi merged commit 52b9e3b into main Jan 30, 2024
19 checks passed
@InesNi InesNi deleted the ifazlic-art-1538-implement-common-platforms-config-templates-for-otel branch January 30, 2024 12:51
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant