-
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
[v2][storage] Implement read path for v2 storage interface #6170
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #6170 +/- ##
==========================================
- Coverage 96.24% 96.22% -0.03%
==========================================
Files 356 356
Lines 20432 20454 +22
==========================================
+ Hits 19665 19681 +16
- Misses 581 585 +4
- Partials 186 188 +2
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. |
cmd/jaeger/internal/extension/jaegerstorage/factoryadapter/reader.go
Outdated
Show resolved
Hide resolved
377d27f
to
2321c76
Compare
…reader (#6221) ## Which problem is this PR solving? - Towards #5079 ## Description of the changes - This PR implements the v2 `spanstore.Reader` interface in the factory adapter through the `TraceReader`, which is currently just a wrapper around the v1 `spanstore.Reader`. The `TraceReader` provides a function `GetV1Reader` that exposes the underlying v1 reader which will be used in #6170. ## How was this change tested? - Added unit tests for new functions ## 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`: `yarn lint` and `yarn test` --------- Signed-off-by: Mahad Zaryab <[email protected]>
Signed-off-by: Mahad Zaryab <[email protected]>
Signed-off-by: Mahad Zaryab <[email protected]>
Signed-off-by: Mahad Zaryab <[email protected]>
Signed-off-by: Mahad Zaryab <[email protected]>
Signed-off-by: Mahad Zaryab <[email protected]>
Signed-off-by: Mahad Zaryab <[email protected]>
Signed-off-by: Mahad Zaryab <[email protected]>
Signed-off-by: Mahad Zaryab <[email protected]>
Signed-off-by: Mahad Zaryab <[email protected]>
} | ||
|
||
depReader, err := f.CreateDependencyReader() | ||
depReader, err := v1Factory.CreateDependencyReader() |
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.
would it make sense to create storage_v2/depstore/
before continuing, so that we don't have to keep this bifurcation?
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.
@yurishkuro Sure. What do we want to put in that package?
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.
a refactoring suggestion:
- storage_v/spanstore -> storage_v/tracestore
Signed-off-by: Mahad Zaryab <[email protected]>
Signed-off-by: Mahad Zaryab <[email protected]>
|
Signed-off-by: Mahad Zaryab <[email protected]>
Signed-off-by: Mahad Zaryab <[email protected]>
Signed-off-by: Mahad Zaryab <[email protected]>
@@ -40,15 +42,15 @@ type StorageCapabilities struct { | |||
|
|||
// QueryService contains span utils required by the query-service. | |||
type QueryService struct { | |||
spanReader spanstore.Reader | |||
traceReader tracestore.Reader |
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.
what about archive reader/writer, any reason not to upgrade them too? (or PR is too large?)
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.
@yurishkuro I initially thought that we couldn't do this yet because I thought we were using the ArchiveFactory
interface here. However, it seems like we just use the normal reader interface on the archive reader as well (see https://github.com/jaegertracing/jaeger/blob/main/cmd/query/app/querysvc/query_service.go#L69) so this can be done. I can do it in this PR or a separate one. Let me know if you have a preference.
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.
Because of the other question (not having v2 reader fully implemented) it's ok to do these separately, no particular benefit afaict.
comments / errors Signed-off-by: Yuri Shkuro <[email protected]>
Signed-off-by: Yuri Shkuro <[email protected]>
Signed-off-by: Yuri Shkuro <[email protected]>
Which problem is this PR solving?
Description of the changes
How was this change tested?
Checklist
jaeger
:make lint test
jaeger-ui
:yarn lint
andyarn test