Seriously.
Keep a small table of open jobs in a database table. For each step open a transaction, select a job, and attempt to do one step. If you succeed update the table with the new information about what comes next and commit the transaction. If you fail send email and rollback the transaction. Should you crash unexpectedly, it is up to the database to ensure that there is a reliable record of your current state.
Just be sure that each of your labelled steps is one which from the time you open a transaction to the time you commit it, can be restarted from scratch without penalty.
Should you wish to create a log of your actions, that log can be kept in the database as well.
In reply to Re (tilly) 1: Mechanisms for Fault-Tolerant Perl Scripting
by tilly
in thread Mechanisms for Fault-Tolerant Perl Scripting
by princepawn
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |