fixed time_since_heartbeat() so it works when there is no heartbeat
claim_and_run() now handles edge case of multiple subs active for the same job