diff --git a/dags/business/business/community/avg_cost.py b/dags/business/business/community/avg_cost.py index e73be89..48ab318 100644 --- a/dags/business/business/community/avg_cost.py +++ b/dags/business/business/community/avg_cost.py @@ -144,7 +144,7 @@ def sync(city=None): seaweed_df.loc[index, 'avg_cost'] = price else: seaweed_df.loc[index, 'avg_cost'] = None - with ThreadPoolExecutor(max_workers=30) as pool: + with ThreadPoolExecutor(max_workers=20) as pool: for index, item in seaweed_df.iterrows(): pool.submit(find_around_price_item, index, item) # for index, item in seaweed_df.iterrows(): diff --git a/dags/business/business/community/estate_charge_complete.py b/dags/business/business/community/estate_charge_complete.py index becd95e..f1f9947 100644 --- a/dags/business/business/community/estate_charge_complete.py +++ b/dags/business/business/community/estate_charge_complete.py @@ -110,7 +110,7 @@ def sync_by_city(city_now): log.info(f"{city_now}开始补充物业费....") sql = "select id, city, region, name, estate_charge, finish_building_date, location from community_summary where city='" + city_now + "' and (estate_charge is null or estate_charge_flag=1)" community_summary_df = es206_client.scan_by_sql_to_data_frame(sql) - with ThreadPoolExecutor(max_workers=50) as pool: + with ThreadPoolExecutor(max_workers=20) as pool: def deal(index, item): if index % 1000 == 0 and index > 0: log.info(f"已查找{index}") diff --git a/dags/business/business/community/relative_price_ranking.py b/dags/business/business/community/relative_price_ranking.py index 2bc9117..effbbd6 100644 --- a/dags/business/business/community/relative_price_ranking.py +++ b/dags/business/business/community/relative_price_ranking.py @@ -78,7 +78,7 @@ def sync(city=None): elif len(around_seaweed_df) == 1: seaweed_df.loc[index, 'relative_price_ranking'] = 0.5 - with ThreadPoolExecutor(max_workers=30) as pool: + with ThreadPoolExecutor(max_workers=20) as pool: for index, item in seaweed_df.iterrows(): pool.submit(find_around_price_item, index, item)