feat: [WIP] Implement datadog v0.7 traces api #249
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Fixes
I've added an option to export traces using the
v0.7
api endpoint to datadog. I needed this because as opposed to thev0.5
endpoint, the new one is able to export span links and events.I've tested my code by using the test agent and added a link in the code as well so that others might find it useful. Also tested against a real datadog instance and everything seems to work correctly.
Design discussion issue (if applicable)
Since the
v0.7
endpoint uses message pack encoding with string keys, it's possible to make the code nicer and probably safer by using rmp_serde. I wasn't sure if you wanted to pull in another dependency, so for now I implemented the serialization without it. Tell me if you want to change it :)Changes
All changes are contained in the
opentelemetry-datadog
crate, mostly in theopentelemetry-datadog/src/exporter/model/v07.rs
file.Merge requirement checklist
CHANGELOG.md
files updated for non-trivial, user-facing changes