-
Notifications
You must be signed in to change notification settings - Fork 2.5k
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
[refactor] Move model<->otlp translation from jptrace
to v1adapter
#6414
[refactor] Move model<->otlp translation from jptrace
to v1adapter
#6414
Conversation
Signed-off-by: Mahad Zaryab <[email protected]>
Signed-off-by: Mahad Zaryab <[email protected]>
storage_v2/v1adapter/translator.go
Outdated
@@ -24,7 +25,7 @@ func ProtoFromTraces(traces ptrace.Traces) []*model.Batch { | |||
// to OpenTelemetry traces (ptrace.Traces). | |||
func ProtoToTraces(batches []*model.Batch) ptrace.Traces { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can we change the name of the function? E.g. ModelBatchesToTraces. Because in some cases it's also useful to have model.Trace as input/output, not just model.Batch, and the naming does not allow that.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
or even better V1BatchesToTraces
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #6414 +/- ##
=======================================
Coverage 96.25% 96.25%
=======================================
Files 368 368
Lines 20979 20979
=======================================
Hits 20193 20193
Misses 601 601
Partials 185 185
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
Signed-off-by: Mahad Zaryab <[email protected]>
jaegertracing#6414) ## Description of the changes - Move model<->otlp translation from `jptrace` to `v1adapter` to keep `jptrace` specific to helper around the `ptrace` domain objects. ## How was this change tested? - CI ## Checklist - [x] I have read https://github.com/jaegertracing/jaeger/blob/master/CONTRIBUTING_GUIDELINES.md - [x] I have signed all commits - [x] I have added unit tests for the new functionality - [x] I have run lint and test steps successfully - for `jaeger`: `make lint test` - for `jaeger-ui`: `npm run lint` and `npm run test` --------- Signed-off-by: Mahad Zaryab <[email protected]>
Description of the changes
jptrace
tov1adapter
to keepjptrace
specific to helper around theptrace
domain objects.How was this change tested?
Checklist
jaeger
:make lint test
jaeger-ui
:npm run lint
andnpm run test