예제 #1
0
def cleandb():
    from ooredis import get_client
    cl = get_client()
    cl.flushdb()
예제 #2
0
def get_dbsize():
    '''Returns the number of keys in the current database'''
    from ooredis import get_client
    cl = get_client()
    return cl.dbsize()
예제 #3
0
def lastsave():
    from ooredis import get_client
    cl = get_client()
    return cl.lastsave()
예제 #4
0
def get_all_keys():
    from ooredis import get_client
    cl = get_client()
    return cl.keys()
예제 #5
0
def safe_exit():
    from ooredis import get_client
    cl = get_client()
    cl.save()
    cl.shutdown()
예제 #6
0
def shutdown():
    from ooredis import get_client
    cl = get_client()
    cl.shutdown()
예제 #7
0
def get_info():
    '''Returns a dictionary containing information about the Redis server'''
    from ooredis import get_client
    cl = get_client()
    return cl.info()
예제 #8
0
def bgsave():
    from ooredis import get_client
    cl = get_client()
    cl.bgsave()
예제 #9
0
def save_db():
    from ooredis import get_client
    cl = get_client()
    cl.save()