-
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
interop/xds: Interop client and server changes for CSM Observability #7280
Conversation
93a2f4b
to
59e5a4c
Compare
Thanks for the pass sorry for the hassle; interop still works on latest commit |
interop/xds/client/client
Outdated
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.
Please remove.
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.
Whoops, deleted.
interop/xds/client/client.go
Outdated
provider := metric.NewMeterProvider( | ||
metric.WithReader(exporter), | ||
) | ||
go http.ListenAndServe(":9464", promhttp.Handler()) |
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.
Please add port flag and use it here.
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 environment variable, whatever is decided.
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.
Decided to do env var "OTEL_EXPORTER_PROMETHEUS_PORT" with default of 9464. Interop test won't set and will default.
interop/xds/client/client.go
Outdated
provider := metric.NewMeterProvider( | ||
metric.WithReader(exporter), | ||
) | ||
go http.ListenAndServe(":9464", promhttp.Handler()) |
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.
Should we do something like go func() { if err := ListenAndServe; err != nil { logger.Fatalf } }()
, so if the port is taken we get a noisy error instead of just things not working right?
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.
Done for both client and server.
Verified recent commits with another interop pass. |
interop/xds/client/Dockerfile
Outdated
@@ -24,13 +24,13 @@ COPY . . | |||
|
|||
# Build a static binary without cgo so that we can copy just the binary in the | |||
# final image, and can get rid of Go compiler and gRPC-Go dependencies. | |||
RUN go build -tags osusergo,netgo interop/xds/client/client.go | |||
RUN cd interop/xds/client && go build -tags osusergo,netgo client.go |
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.
How about .
?
I think if you specify the file here and we add another file, it will break.
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.
Done.
interop/xds/server/Dockerfile
Outdated
@@ -24,13 +24,13 @@ COPY . . | |||
|
|||
# Build a static binary without cgo so that we can copy just the binary in the | |||
# final image, and can get rid of the Go compiler and gRPC-Go dependencies. | |||
RUN go build -tags osusergo,netgo interop/xds/server/server.go | |||
RUN cd interop/xds/server && go build -tags osusergo,netgo server.go |
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.
As above, build .
is probably better
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.
Done.
e76b1b6
to
4484a86
Compare
Continues to pass; merging. |
This PR adds the CSM Observability flags for interop testing. It makes the xDS interop client and server their own go.mod to avoid upgrading the minimum required go version of the top level grpc/ go.mod to require go 1.21, as the client and server take a transitive OpenTelemetry dependency through the csm package, which requires go 1.21.
RELEASE NOTES: N/A