appengine-java-vm-runtime icon indicating copy to clipboard operation
appengine-java-vm-runtime copied to clipboard

Integrate Google Cloud Trace integration the runtime.

Open aozarov opened this issue 9 years ago • 2 comments

Currently we pass along the incoming X-Cloud-Trace-Context header to remote API calls and those are being sent to Google Cloud trace from the appserver.

We could use https://github.com/GoogleCloudPlatform/cloud-trace-java (though I think there is a new version coming up that would be part of AE lab apis) to allow both Jetty and application code to create Trace Spans. We should also use the "current" span id when setting up the X-Cloud-Trace-Context header in RemoteApi calls (to tie RPC to the correct span). Once request is completed we should collect the current Trace and all its created spans and send to the Google Cloud Trace.

aozarov avatar May 17 '16 22:05 aozarov

@aozarov The current traceid integration is done as follows:

I'm not sure if there are any unit tests for this, but I have seen trace-id in some log messages. However they are buried in the JSON and you need to click open several layers to see them. However you can use the GAE log tools to filter on the values.

gregw avatar May 18 '16 23:05 gregw

Design doc is here: https://docs.google.com/a/google.com/document/d/1hyqxUbxDBsP6cdLI23Nl2vZWr1YIOPJXPxN283SdJW4/edit?usp=sharing (access is restricted).

aozarov avatar Jun 02 '16 00:06 aozarov