News for hackers. Stuff that matters.
Re:Kill Me Softly – Kill processes in a reliable manner by angersock on Tuesday December 16, 2014 @05:42PM (#8760054)
You very much can--it depends on what you're doing.

Supporting SIGTERM and certain other signals is just deciding how big a crater you want to make when the program goes down. That said, it's good practice to use things (write-ahead logging, idempotent operations, etc.) that at least try to mitigate the amount of debris.

Re:Kill Me Softly – Kill processes in a reliable manner by rdtsc on Tuesday December 16, 2014 @06:09PM (#8760171)
> That said, it's good practice to use things (write-ahead logging, idempotent operations, etc.) that at least try to mitigate the amount of debris.

Yap that are some of the things I used. Append only mode for files. Code that handle roll-back to last consistent state that runs on every startup. External monitors and watchdog that know how to monitor and to extra cleanup is necessary.