f26fe223 by 冯轩

MOD:celery

1 parent ce3a0eaa
...@@ -8,4 +8,4 @@ broker = conf.CELERY_BROKER_URL ...@@ -8,4 +8,4 @@ broker = conf.CELERY_BROKER_URL
8 8
9 app = Celery('celery_compare', broker=broker, include=['celery_compare.tasks']) 9 app = Celery('celery_compare', broker=broker, include=['celery_compare.tasks'])
10 10
11 app.conf.update(worker_max_tasks_per_child=5, timezone='Asia/Shanghai') 11 app.conf.update(worker_max_tasks_per_child=10, timezone='Asia/Shanghai')
......
...@@ -3730,7 +3730,7 @@ def fsm_compare(application_id, application_entity, uniq_seq, ocr_res_id, is_ca= ...@@ -3730,7 +3730,7 @@ def fsm_compare(application_id, application_entity, uniq_seq, ocr_res_id, is_ca=
3730 # results = list(executor.map(fsm_compare_thread, application_id, application_entity, uniq_seq, ocr_res_id, is_ca, is_cms)) 3730 # results = list(executor.map(fsm_compare_thread, application_id, application_entity, uniq_seq, ocr_res_id, is_ca, is_cms))
3731 3731
3732 compare_log.info('[fsm thread]') 3732 compare_log.info('[fsm thread]')
3733 pool = ThreadPoolExecutor(max_workers=5, thread_name_prefix="fsm_thread_") 3733 pool = ThreadPoolExecutor(max_workers=6, thread_name_prefix="fsm_thread_")
3734 pool.submit(fsm_compare_thread, application_id, application_entity, uniq_seq, ocr_res_id, is_ca, is_cms) 3734 pool.submit(fsm_compare_thread, application_id, application_entity, uniq_seq, ocr_res_id, is_ca, is_cms)
3735 pool.shutdown(wait=True) 3735 pool.shutdown(wait=True)
3736 3736
...@@ -3808,7 +3808,7 @@ def compare(application_id, application_entity, uniq_seq, ocr_res_id, is_ca=True ...@@ -3808,7 +3808,7 @@ def compare(application_id, application_entity, uniq_seq, ocr_res_id, is_ca=True
3808 # results = list(executor.map(compare_thread, application_id, application_entity, uniq_seq, ocr_res_id, is_ca, is_cms)) 3808 # results = list(executor.map(compare_thread, application_id, application_entity, uniq_seq, ocr_res_id, is_ca, is_cms))
3809 3809
3810 compare_log.info('[non fsm thread]') 3810 compare_log.info('[non fsm thread]')
3811 pool = ThreadPoolExecutor(max_workers=5, thread_name_prefix="non_fsm_thread_") 3811 pool = ThreadPoolExecutor(max_workers=6, thread_name_prefix="non_fsm_thread_")
3812 pool.submit(compare_thread, application_id, application_entity, uniq_seq, ocr_res_id, is_ca, is_cms) 3812 pool.submit(compare_thread, application_id, application_entity, uniq_seq, ocr_res_id, is_ca, is_cms)
3813 pool.shutdown(wait=True) 3813 pool.shutdown(wait=True)
3814 3814
......
Styling with Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!