-
Notifications
You must be signed in to change notification settings - Fork 2.6k
[chore] Remove gogoproto annotations from trace_storage.proto
and dependency_storage.proto
#6819
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
[chore] Remove gogoproto annotations from trace_storage.proto
and dependency_storage.proto
#6819
Conversation
Signed-off-by: Mahad Zaryab <mahadzaryab1@gmail.com>
Signed-off-by: Mahad Zaryab <mahadzaryab1@gmail.com>
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #6819 +/- ##
==========================================
- Coverage 96.06% 96.02% -0.04%
==========================================
Files 364 364
Lines 20712 20712
==========================================
- Hits 19897 19889 -8
- Misses 622 628 +6
- Partials 193 195 +2
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
let's inject then back with SED |
Signed-off-by: Mahad Zaryab <mahadzaryab1@gmail.com>
Signed-off-by: Mahad Zaryab <mahadzaryab1@gmail.com>
Signed-off-by: Mahad Zaryab <mahadzaryab1@gmail.com>
Signed-off-by: Mahad Zaryab <mahadzaryab1@gmail.com>
scripts/makefiles/Protobuf.mk
Outdated
patch-storage-v2: | ||
mkdir -p proto-gen/.patched/storage_v2 | ||
cp internal/storage/v2/grpc/trace_storage.proto proto-gen/.patched/storage_v2/ | ||
cp internal/storage/v2/grpc/dependency_storage.proto proto-gen/.patched/storage_v2/ |
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.
Why copy? It will get overwritten, is it not?
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.
Changed it to follow the same structure as the command for api_v3
@@ -135,7 +147,7 @@ API_V3_PATCHED=$(API_V3_PATCHED_DIR)/query_service.proto | |||
patch-api-v3: | |||
mkdir -p $(API_V3_PATCHED_DIR) | |||
cat idl/proto/api_v3/query_service.proto | \ | |||
$(SED) -f ./proto-gen/patch-api-v3.sed \ | |||
$(SED) -f ./proto-gen/patch.sed \ |
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.
I didn't realize the sed file is reusable.
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.
yeah its just a generic file that adds annotations for timestamps and durations
s|import "google/protobuf/duration.proto";|import "google/protobuf/duration.proto";\
\
import "gogoproto/gogo.proto";\
\
option (gogoproto.marshaler_all) = true;\
option (gogoproto.unmarshaler_all) = true;\
option (gogoproto.sizer_all) = true;\
|g
s|google.protobuf.Timestamp \(.*\);|google.protobuf.Timestamp \1 \
[\
(gogoproto.nullable) = false,\
(gogoproto.stdtime) = true\
];|g
s|google.protobuf.Duration \(.*\);|google.protobuf.Duration \1 \
[\
(gogoproto.nullable) = false,\
(gogoproto.stdduration) = true\
];|g
Signed-off-by: Mahad Zaryab <mahadzaryab1@gmail.com>
Signed-off-by: Mahad Zaryab <mahadzaryab1@gmail.com>
…dependency_storage.proto` (jaegertracing#6819) <!-- !! Please DELETE this comment before posting. We appreciate your contribution to the Jaeger project! 👋🎉 --> ## Which problem is this PR solving? - Towards jaegertracing#6789 ## Description of the changes - This PR removes the gogoproto annotations from `trace_storage.proto` and `dependency_storage.proto` to avoid introducing a dependency on gogo for users. Instead, it uses a similar patching mechanism to api_v3 to add the annotations when generating the *.pb.go files. ## 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 <mahadzaryab1@gmail.com>
…dependency_storage.proto` (jaegertracing#6819) <!-- !! Please DELETE this comment before posting. We appreciate your contribution to the Jaeger project! 👋🎉 --> ## Which problem is this PR solving? - Towards jaegertracing#6789 ## Description of the changes - This PR removes the gogoproto annotations from `trace_storage.proto` and `dependency_storage.proto` to avoid introducing a dependency on gogo for users. Instead, it uses a similar patching mechanism to api_v3 to add the annotations when generating the *.pb.go files. ## 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 <mahadzaryab1@gmail.com> Signed-off-by: amol-verma-allen <amol.verma@allen.in>
Which problem is this PR solving?
Description of the changes
trace_storage.proto
anddependency_storage.proto
to avoid introducing a dependency on gogo for users. Instead, it uses a similar patching mechanism to api_v3 to add the annotations when generating the *.pb.go files.How was this change tested?
Checklist
jaeger
:make lint test
jaeger-ui
:npm run lint
andnpm run test