优化评级
This commit is contained in:
@@ -58,7 +58,7 @@ def calc_price_rating(city=None):
|
|||||||
row = dict()
|
row = dict()
|
||||||
_id = str(item["_id"])
|
_id = str(item["_id"])
|
||||||
row['price_rating'] = item['price_rating']
|
row['price_rating'] = item['price_rating']
|
||||||
row['avg_price'] = item['avg_price']
|
row['price_score'] = item['price_score']
|
||||||
|
|
||||||
action = {'_op_type': 'update',
|
action = {'_op_type': 'update',
|
||||||
'_index': index_name,
|
'_index': index_name,
|
||||||
|
|||||||
@@ -50,14 +50,14 @@ with DAG(
|
|||||||
# task_id='relative_price_ranking_dag',
|
# task_id='relative_price_ranking_dag',
|
||||||
# bash_command='python /opt/airflow/dags/repo/dags/business/business/community/relative_price_ranking.py {{dag_run.conf["type"] if "type" in dag_run.conf}}',
|
# bash_command='python /opt/airflow/dags/repo/dags/business/business/community/relative_price_ranking.py {{dag_run.conf["type"] if "type" in dag_run.conf}}',
|
||||||
# )
|
# )
|
||||||
t11 = BashOperator(
|
# t11 = BashOperator(
|
||||||
task_id='consumption_dag',
|
# task_id='consumption_dag',
|
||||||
bash_command='python /opt/airflow/dags/repo/dags/business/business/community/consumption.py {{dag_run.conf["type"] if "type" in dag_run.conf}}',
|
# bash_command='python /opt/airflow/dags/repo/dags/business/business/community/consumption.py {{dag_run.conf["type"] if "type" in dag_run.conf}}',
|
||||||
)
|
# )
|
||||||
t12 = BashOperator(
|
t12 = BashOperator(
|
||||||
task_id='price_rating_dag',
|
task_id='price_rating_dag',
|
||||||
bash_command='python /opt/airflow/dags/repo/dags/business/business/community/price_rating.py {{dag_run.conf["type"] if "type" in dag_run.conf}}',
|
bash_command='python /opt/airflow/dags/repo/dags/business/business/community/price_rating.py {{dag_run.conf["type"] if "type" in dag_run.conf}}',
|
||||||
)
|
)
|
||||||
|
|
||||||
# t1 >> t2 >> t3 >> t4 >> t5 >> t6 >> t7 >> t8 >> t9 >> t10 >> t11 >> t12
|
# t1 >> t2 >> t3 >> t4 >> t5 >> t6 >> t7 >> t8 >> t9 >> t10 >> t11 >> t12
|
||||||
t11 >> t12
|
t12
|
||||||
Reference in New Issue
Block a user