Exemplo n.º 1
0
def update_cache():
    global cached_info
    global cache_expiration

    if not cached_info or cache_expiration < time.time():
        xmlrpc = XmlRpcServer (OWS_APPS_AUTH, OWS_Login.login_user, OWS_Login.login_password)
        cached_info = xmlrpc.get_user_apps()
        cache_expiration = time.time() + EXPIRATION
Exemplo n.º 2
0
def update_cache():
    global cached_info
    global cache_expiration

    if not cached_info or cache_expiration < time.time():
        xmlrpc = XmlRpcServer(OWS_APPS_AUTH, OWS_Login.login_user,
                              OWS_Login.login_password)
        cached_info = xmlrpc.get_user_apps()
        cache_expiration = time.time() + EXPIRATION