more robust worker cleanup