Add AlwaysRecordSampler
Description
Adds a new AlwaysRecordSampler as per:
- Spec issue: https://github.com/open-telemetry/opentelemetry-specification/issues/4698
- Spec PR: https://github.com/open-telemetry/opentelemetry-specification/pull/4699
This sampler behaves the same as it's root sampler, with the exception that it will replace any DROP decisions with an equivalent RECORD one, while maintaining the attributes and trace state from the decision created by the root sampler.
Also renamed the folder holding the tests for experimental sampling features from composite_sampler to sampling_experimental, as more than just the composite sampler is being tested in this folder, respecting the organization of the files in the src folder.
Type of change
- [x] New feature (non-breaking change which adds functionality)
How Has This Been Tested?
Unit tests
Does This PR Require a Contrib Repo Change?
- [ ] Yes. - Link to PR:
- [x] No.
Checklist:
- [x] Followed the style guidelines of this project
- [ ] Changelogs have been updated
- [x] Unit tests have been added
- [ ] Documentation has been updated
We need to wait for the specs to be approved and released before merging this
@xrmx spec is merged, ready for review!