add cancel task, add heartbeat