The GCP CSM Observability example consists of a Hello World client and a Hello World server and shows how to configure CSM Observability for gRPC client and gRPC server.
CsmObservabilityClient
takes the following command-line arguments -
xds:///helloworld:50051
.9464
.CsmObservabilityServer
takes the following command-line arguments -
50051
.9464
.From the grpc-java/examples/
directory i.e,
cd grpc-java/examples
Run the following to generate client and server images respectively.
Client:
docker build -f example-gcp-csm-observability/csm-client.Dockerfile .
Server:
docker build -f example-gcp-csm-observability/csm-server.Dockerfile .
To push to a registry, add a tag to the image either by adding a -t
flag to docker build
command above or run:
docker image tag ${sha from build command above} ${tag}
And then push the tagged image using docker push
.