Wrapper for cron jobs which implements common housekeeping tasks