def domain_for_proxy():
    if CONF.use_domain_for_proxy_users is False:
        return None
    if CONF.proxy_user_domain_name is None:
        raise ex.ConfigurationError(_('Proxy domain requested but not '
                                      'specified.'))
    admin = k.client_for_admin()

    global PROXY_DOMAIN
    if not PROXY_DOMAIN:
        domain_list = b.execute_with_retries(
            admin.domains.list, name=CONF.proxy_user_domain_name)
        if len(domain_list) == 0:
            raise ex.NotFoundException(
                value=CONF.proxy_user_domain_name,
                message_template=_('Failed to find domain %s'))
        # the domain name should be globally unique in Keystone
        if len(domain_list) > 1:
            raise ex.NotFoundException(
                value=CONF.proxy_user_domain_name,
                message_template=_('Unexpected results found when searching '
                                   'for domain %s'))
        PROXY_DOMAIN = domain_list[0]
    return PROXY_DOMAIN
Add/update the node in Redis. Needs to be called regularly by the
dataset/ETHPy150Open openstack/sahara/sahara/utils/proxy.py/domain_for_proxy--crossover with--dataset/ETHPy150Open closeio/redis-hashring/redis_hashring/__init__.py/RingNode.heartbeat