4 ms·
One problem with backups is that you don’t want them to be always online (store them offline and off site for disaster recovery). Backups can also be helpful in
by Matt3o12_ 8y ago
One problem with backups is that you don’t want them to be always online (store them offline and off site for disaster recovery). Backups can also be helpful in case of bugs that delete your whole database so that you can recover the data after the bug is fixed. Imagine the follow query `delete from users where id = 372936 or status = inactive`. Unfortunately, due to a bug, all users have been marked as inactive. Now you destroyed the whole database. No problem you think, just restore it from a backup. Due to the new law, this script ran also on your backup. Congratulations, you have now lost all your users. Hence, you never want to “change” backups. You only ever want to restore from them.
The easiest way to comply with it would be have a list with all user deletion requests stored somewhere else and every time you restore from a backup, you also apply this list from the backup. But have you really deleted users if you keep backups?
- exergy 8y agoIt's not a shell script that you will write each time a user asks for a deletion though, would it? It will be a carefully tested and automated procedure. It certainly sounds like the possibility of deleting all your users might actually make us all more careful, less gun-slinging, shoot-from-the-hip programmers.
- LoSboccacc 8y agoIf backups are now live data you need to backup the backups. What happens if the procedure bugs out? It’s backups and scripts all the way down.
- Matt3o12_ 8y agoIt will probably be an SQL query and if software development has thought us anything is that testing is not enough. Proper testing can be very helpful and prevent many errors but it can never prevent all because you just cannot test for all circumstances. This is why backups are helpful and why backups should not be changeable. It is a reason why backups were made on magnetic tab back in the day so it wouldn’t be overridden by mistake. Backups were just as important back when programming wasn’t all about that fast iterating and push updates and fix later – or gun-slinging programming as you call it – as they are now.