Your Present & Future Self Will Hate You For Forgetting To Do This Programming Chore
Nothing will ruin a programming session faster than bad coffee shop WiFi. And on the particular day I’m recounting, as much as I needed the vanilla latte sitting to my left, I really needed that sweet, sweet public broadband because the power was out at home and, more importantly, so was the coffee.
I needed all the caffeine I could get because even though I was deep in our tech stack, in the three hours I was online, I hadn’t written a line of code. Instead, I was doing something you wouldn’t normally associate with technical work: Reading. While some coffee shop patrons were reading novels, magazines and blog posts I was engrossed in my team’s logs.
How to Use Logging Query Language to Analyze GCP Logs Data in Python
How to use Google Cloud’s Logs API and Logging Query Language in Python to obtain real-time data on active GCP…
medium.com
Reviewing our various processes, I was surprised at the scope and variety of the logs I encountered. Some extensively logged every function execution and every API response.
Others only provided logs to signal the start and end of a script’s execution. After my review I flagged these under-logged products and the team revised logs so the majority of our products are legible and extensively logged.
That exercise and my own experience building data pipelines made me realize that new developers are all too often making the same mistake: You’re treating logs like code when you should be treating them like units of communication.