Join GitHub today
GitHub is home to over 28 million developers working together to host and review code, manage projects, and build software together.Sign up
Log Correlation from App Engine Standard PHP 7.2 #1277
I'm trying to write logs from App Engine Standard on the new PHP 7.2 runtime, but the log correlation back to the main request isn't working out of the box.
From the documentation :
However, the logs get written with just the TRACE_ID in that field, not the full string it expects.
I followed it back to the metadata provider  which was designed for Flex, which sets it in the old location (the
Can somebody help please?
It seems as though we should be able to update the linked code to the following:
$options['trace'] = sprintf( 'projects/%s/trace/%s', $this->projectId, // currently this is not accessible in the `PsrLogger`, we will need to devise a way to expose it $labels['appengine.googleapis.com/trace_id'] );
/cc @tmatsuo to confirm if this seems like a proper way to proceed.