add option to send more than one heartbeat message