Open sciurus opened 3 years ago
@jbuck anything else come to your mind that the proxy should log?
hmmm, are there any other upstream headers that we'd be interested in logging? other than that, latency and response code is good
I can't think of any headers we'd want that aren't in the nginx logs, and once we have x-cloud-trace logged by the app we can tie the two together.
Right now, when the top sites proxy returns an error code like 500 it is difficult to determine if it is because
a) the partner returned this error and we are proxying the response b) the proxy itself experienced an error
I think a good way to address this is to add some more fields to the logs. Here are two that I would find useful specifically for requests under /cid/
and here are three I'd find useful for all requests.
For timings, seconds with millisecond accuracy (e.g. 0.123) would be good. If for some reason we didn't receive or send a response code, we could log 0.