https://github.com/GoogleCloudPlatform/google-cloud-go/blob/master/trace/trace.go
This is an example repo for getting Google's Stackdriver Trace tracing requests across microservices.
Go to Billing to set up a billing account & make sure it is enabled for the new project you created.
- click "Enable API"
- search "trace"
- select "Stackdriver Trace API"
- click "Enable"
Go to Service Accounts
- click "Create service account"
- name it "tracer"
- select the Role of "Cloud Trace Agent"
- select "Furnish a new private key"
- click "CREATE"
The JSON key will be downloaded.
export GCP_PROJECT={project id of the new project you created}
export GCP_KEY={full path of the service account key file that you just downloaded}
git clone http://github.com/jrkt/go-tracing-lab $GOPATH/src/github.com/jrkt/go-tracing-lab
Hello World
Silicon Valley Conversation
- Get code
go get -u github.com/golang/protobuf/{proto,protoc-gen-go}
go get -u google.golang.org/grpc
- Install protoc
wget https://github.com/google/protobuf/releases/download/v3.2.0rc2/protoc-3.2.0rc2-linux-x86_64.zip
unzip protoc-3.2.0rc2-linux-x86_64.zip
sudo cp bin/protoc /usr/local/bin