implement getHosts