2 ms·
Idempotency is something I think about constantly. It's part of my Optimize For Sleep® development philosophy. You have to assume that 1) your program can and w
by spyspy 4y ago
Idempotency is something I think about constantly. It's part of my Optimize For Sleep® development philosophy. You have to assume that 1) your program can and will fail at any arbitrary point during execution and 2) the caller of your code will retry it with reckless abandon every time it fails (or even if it doesn't). I know this because I am often on both sides of my own code, the writer and the caller. Managing state to avoid side effects takes a lot of mental effort and devs often get complacent or rush through it, but eventually it is going to burn you.