def is_hosting_device_reachable(self, hosting_device):
ret_val = False<EOL>hd = hosting_device<EOL>hd_id = hosting_device['<STR_LIT:id>']<EOL>hd_mgmt_ip = hosting_device['<STR_LIT>']<EOL>dead_hd_list = self.get_dead_hosting_devices_info()<EOL>if hd_id in dead_hd_list:<EOL><INDENT>LOG.debug("<STR_LIT>"<EOL>"<STR_LIT>",<EOL>{'<STR_LIT>': hd_id, '<STR_LIT>': hd_mgmt_ip})<EOL>return False<EOL><DEDENT>if not isinstance(hd['<STR_LIT>'], datetime.datetime):<EOL><INDENT>hd['<STR_LIT>'] = datetime.datetime.strptime(hd['<STR_LIT>'],<EOL>'<STR_LIT>')<EOL><DEDENT>if _is_pingable(hd_mgmt_ip):<EOL><INDENT>LOG.debug("<STR_LIT>",<EOL>{'<STR_LIT>': hd_id, '<STR_LIT>': hd_mgmt_ip})<EOL>hd['<STR_LIT>'] = cc.HD_ACTIVE<EOL>ret_val = True<EOL><DEDENT>else:<EOL><INDENT>LOG.debug("<STR_LIT>",<EOL>{'<STR_LIT>': hd_id, '<STR_LIT>': hd_mgmt_ip})<EOL>hd['<STR_LIT>'] = cc.HD_NOT_RESPONDING<EOL>ret_val = False<EOL><DEDENT>if self.enable_heartbeat is True or ret_val is False:<EOL><INDENT>self.backlog_hosting_device(hd)<EOL><DEDENT>return ret_val<EOL>
Check the hosting device which hosts this resource is reachable.

        If the resource is not reachable, it is added to the backlog.

        * heartbeat revision

        We want to enqueue all hosting-devices into the backlog for
        monitoring purposes

        adds key/value pairs to  hd (aka hosting_device dictionary)

        _is_pingable : if it returns true,
            hd['hd_state']='Active'
        _is_pingable : if it returns false,
            hd['hd_state']='Unknown'

        :param hosting_device : dict of the hosting device
        :returns: True if device is reachable, else None