[Haskell-cafe] Logging

Joachim Durchholz jo at durchholz.org
Sun Nov 21 21:47:11 UTC 2021

Am 21.11.21 um 19:18 schrieb Tom Ellis:
> It sounds really unwise to log timestamps in anything in other than
> UTC.  If you want to see the logged times in your local timezone then
> why not apply that conversion when you read the log?

UTC is wise only if you really have to deal with data originating from 
multiple timezones.
Otherwise, it's just an additional interpretation step that makes it 
harder to read the raw logs - which not a very rare use case actually, 
editors are still the fastest way to find specific log records after all 
(mostly because you don't have to learn the web interface du jour just 
to search for something).

E.g. the application I'm working with logs to text files, and it always 
runs in the same time zone.
UTC is just an extra hoop to jump through, with no added benefit.
(Some users do live in a separate time zone, but we rarely need to 
correlate user-side and server-side logs, we go by session ids anyway.)


More information about the Haskell-Cafe mailing list