TiL: Save CPU cycles by logging blocks

We log a lot in our functional tests. In fact, we log so much we wrote our own logger called Herodotus that extends the default Ruby logger so we can have a correlation id added to the log to help keep track of which scenario a given log is from1. But with that much logging, we want to keep things lightweight. That’s where we want to make sure our logs aren’t doing more work than we expect....

December 15, 2023 · 3 min · 587 words · George Bell

Why we wrote Herodotus

We’ve written Herodotus1 as a lightweight logger to solve some very specific problems we had in our tests, but we don’t think they are unique to us so we’re going to share with you what we have done and why. Logging to the standard output and the main problem we faced The problem we are trying to solve is one of readability. All good logs are human readable, as when something has gone wrong to the point of a human needing to look in the logs and piece together what has happened we don’t want to make that more difficult than is needed....

May 17, 2023 · 11 min · 2156 words · George Bell