Skip to content

Instantly share code, notes, and snippets.

@bijoutrouvaille
Created September 7, 2017 16:38
Show Gist options
  • Save bijoutrouvaille/881d3b8780ba2e35e3e4dc3320172189 to your computer and use it in GitHub Desktop.
Save bijoutrouvaille/881d3b8780ba2e35e3e4dc3320172189 to your computer and use it in GitHub Desktop.
stackdriver logger test
logger '{
"message": "Some test message",
"context": {
"reportLocation": {
"functionName": "my_function"
}
},
"serviceContext": {
"service": "my service",
}
}'
{
insertId: "123abc"
labels: {
compute.googleapis.com/resource_name: "my-instance-id"
}
logName: "projects/my-proj/logs/syslog"
receiveTimestamp: "2017-09-07T16:29:05.117088075Z"
resource: {
labels: {
instance_id: "1234"
project_id: "my-proj"
zone: "us-central1-a"
}
type: "gce_instance"
}
textPayload: "Sep 7 16:28:59 my-instance-id my-system-user: { "message": "Some test message", "context": { "reportLocation": { "functionName": "my_function" } }, "serviceContext": { "service": "my service", } }"
timestamp: "2017-09-07T16:28:59Z"
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment