change the heartbeat function, now we can send delete command from heartbeat query.