optimize hosted services lookup.