News for hackers. Stuff that matters.
Re:Ask HN: How do you handle audit logs in your systems? by BrunoBernardino on Tuesday July 29, 2025 @03:28AM (#44720191)
Here's a redacted example interface in TypeScript for something important. It's added to a PostgreSQL database. The "extra" field is a common pattern I use, with JSON, for fields that are frequently added later that don't require indexes or as much data integrity as the other fields, so a migration isn't necessary:

https://gist.github.com/BrunoBernardino/df806e3e902017308abf...

Hope it helps!

There are no comments on this comment yet.