Esempio n. 1
0
def post_update(entity, operation):
    if has_queue():
        entity_ref = to_ref(entity)
        if entity_ref is None:
            return
        data = dict(operation=operation, entity=entity_ref)
        post_message(UPDATE_SERVICE, json.dumps(data))
Esempio n. 2
0
def update_entity(entity, operation):
    entity_ref = to_ref(entity)
    if entity_ref is None:
        return
    data = dict(operation=operation, entity=entity_ref)
    data_json = json.dumps(data)
    return handle_update(data_json)
Esempio n. 3
0
File: index.py Progetto: alkadis/vcv
def gen_id(entity):
    ref = refs.to_ref(entity)
    return hashlib.sha1(ref).hexdigest()
Esempio n. 4
0
def gen_id(entity):
    ref = refs.to_ref(entity)
    return hashlib.sha1(ref).hexdigest()