laravel-stackdriver icon indicating copy to clipboard operation
laravel-stackdriver copied to clipboard

Add request data

Open vincentrolfs opened this issue 5 years ago • 2 comments
trafficstars

  • Remove call to Bootstrap::exceptionHandler and do the boilerplate work ourselves in order to be able to send more data to error reporting
  • Send the following data to error reporting (in addition to what we have always sent):
    • User id
    • Request URL
    • Request method (GET, POST, ...)
    • User agent
    • Referrer URL
    • Client IP
  • Enable users to supply additional context data as they wish

vincentrolfs avatar Jul 29 '20 08:07 vincentrolfs

Things to note:

  • I am not sure if it could be a problem with GDPR that we are automatically logging user id, user agent and client IP on error. Maybe this should be opt-in.
  • I had to copy some code from Google\Cloud\ErrorReporting\Bootstrap which was private static. This code is licensed under Apache 2.0 which is different from our license (MIT). Not sure what the implications of this are.

vincentrolfs avatar Jul 30 '20 05:07 vincentrolfs

Hi, I am sorry, this slipped off my radar.

I indeed do think that adding user data is a bit tricky given GDPR. I think we better make this opt-in. Having checked the Apache 2.0 license, I don't think we'll have any issues here including that code.

DiederikvandenB avatar Oct 12 '20 20:10 DiederikvandenB