PixelogicDev / gruveebackend

This is the Backend work for Gruvee
MIT License
24 stars 4 forks source link

Setup Proper Error Logging #46

Closed LeviHarrison closed 4 years ago

LeviHarrison commented 4 years ago

This pull request implements Google Cloud error logging, as proposed in issue #34 . I've added a new module in pkg called errlog, and implemented that module in all the Serverless and Event functions, excluding tokengen and updatealgolia.

Note: For logging to work you have to enable the Errors Writer role on GCP

LeviHarrison commented 4 years ago

Summary of conversation on Discord: It's been established that Sawmill will focus on error logging for now, and then maybe later Analytics. We've also decided to pivot away from GCP's Error Reporting Product in favor of there more general Logging Product. We've decided to do this because Logging allows us to provide more data, such as the severity of the log. With that will come a switch from the error-reporting client library to the logging one. Diving into the code, Sawmill will log to both GCP and the console, for local development. Pointers will be used to solve issues in passing arguments to the logging function. Finally, this PR will be closed, and a new one will be opened at some point.

adilanchian commented 4 years ago

Closing PR based on Discord and what is mentioned above ^^