Commit d33a5c29 authored by lixiaofang's avatar lixiaofang

add

parent 552ed6c9
# -*- coding: UTF-8 -*-
import logging
import traceback
import json
from celery import shared_task
from django.conf import settings
from django.core import serializers
from trans2es.type_info import get_type_info_map
# from rpc.all import get_rpc_remote_invoker
from libs.es import ESPerform
import logging
import traceback
from libs.cache import redis_client
from trans2es.models.face_user_contrast_similar import FaceUserContrastSimilar,UserSimilarScore
import json
from linucb.utils.register_user_tag import RegisterUserTag
@shared_task
......
......@@ -6,7 +6,6 @@ from celery import shared_task
login_url = "http://earth.igengmei.com/api/account/login_pwd"
def index_first():
try:
r1 = requests.get(login_url)
......@@ -19,7 +18,7 @@ def index_first():
@shared_task
def get_cook():
data = open("majia_email")
data = open("majia_email","r")
list = []
dicts = {}
......
# coding=utf-8
from __future__ import unicode_literals, print_function, absolute_import
import itertools
from django.conf import settings
import itertools
import logging
class CeleryTaskRouter(object):
queue_task_map = {
# "tapir-alpha": [
# 'injection.data_sync.tasks.write_to_es',
# ],
"tapir-alpha": [
'injection.data_sync.tasks.write_to_es',
],
# "majia-alpha": [
# 'injection.data_sync.auto_instant_click.auto_click',
# ],
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment