-
Notifications
You must be signed in to change notification settings - Fork 4.4k
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
gcp/observability: correctly test this module in presubmit tests #5300
Changes from all commits
5fc5d9b
2e9a37e
6941c3c
5185247
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,4 +1,4 @@ | ||
module google.golang.org/grpc/observability | ||
module google.golang.org/grpc/gcp/observability | ||
|
||
go 1.14 | ||
|
||
|
@@ -7,8 +7,10 @@ require ( | |
github.com/golang/protobuf v1.5.2 | ||
github.com/google/uuid v1.3.0 | ||
golang.org/x/oauth2 v0.0.0-20211104180415-d3ed0bb246c8 | ||
google.golang.org/grpc v1.43.0 | ||
google.golang.org/grpc v1.46.0 | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Did this fail to compile? Since 1.43.0 doesn't have the exported binarylog structs. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Yep... this unfortunately is hidden by the There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. So if we make changes in gcp/observability in the future that rely on changes in the main module, we won't ever catch that? Should we delete the There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Added a TODO to remove the
It would be great to decouple them (to allow internal packages to continue be internal). But I'm not sure what's the best practice here. We can strive to use let it use public API in future (by exposing experimental APIs).
Does this solution mean gRPC Observability will impact the dependency tree of all gRPC Go users? That doesn't sound good... There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Giving this another thought. We could aim to only use public methods for future plugins like the observability one? In this case, we were using the internal methods of binary logging to customize the logger. We didn't public them, because we were uncertain if we will keep using this design (wrap binary logging) or if the plugin will stay for the long run. We could find a middle ground here to publicize some hooks if they help users to extend those modules. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Making the APIs public doesn't make this situation better, because changing them will still break our own observability module. From another perspective, maybe this isn't that bad, since at least for now, the observability package is still experimental. And also, we don't make separate releases for the observability module (so that even if it's a separate module, it shared the version of the main module). |
||
google.golang.org/protobuf v1.27.1 | ||
) | ||
|
||
// TODO(lidiz) remove the following line when we have a release containing the | ||
// necessary internal binary logging changes | ||
replace google.golang.org/grpc => ../../ |
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.
This will run the top level tests again.
Limit the
find
?find . -mindepth 2 -name 'go.mod'
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.
In the suggested snippet, the second part is
grep -Ev '^\./go\.mod'
, it excludes the top level tests. Can you double check if current test set works as expected? https://github.com/grpc/grpc-go/runs/5994752478?check_suite_focus=true(It looks reasonable to me, no duplication found)
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.
Oh, I see. I somehow thought that was to remove the go.mod and keep only the directory name. This should be good then!