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): implement smartSampling for Playwright tracing #2453

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

InesNi
Copy link
Contributor

@InesNi InesNi commented Jan 30, 2024

Description

This PR introduces two main changes:

1. smartSampling support for the Playwright engine tracing.

If smartSampling is configured in the test script (as shown below), only traces that have recorded errors will be exported.

  plugins:
    publish-metrics:
      - type: open-telemetry
        traces:
          smartSampling: {}

2. A breaking change is introduced in the smartSampling configuration for the HTTP engine.

The additional optional threshold settings will now be nested inside the http key:

Old config:

  plugins:
    publish-metrics:
      - type: open-telemetry
        traces:
          smartSampling:
            thresholds:
              firstByte: 500
              total: 2000

New config:

  plugins:
    publish-metrics:
      - type: open-telemetry
        traces:
          smartSampling:
            http:
              thresholds:
                firstByte: 500
                total: 2000

Testing

Tested manually by running multiple scenarios with different settings, viewing results on different observability platforms, running locally and with Fargate. All seems to be running properly. See screenshots for one of the tests below

Screenshot 2024-01-31 at 14 22 10 Screenshot 2024-01-31 at 14 13 38 Screenshot 2024-01-31 at 14 15 04

Pre-merge checklist

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

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

1 participant