MOD:max_conn_age,remove queue empty log
Showing
2 changed files
with
2 additions
and
2 deletions
... | @@ -1646,7 +1646,7 @@ class Command(BaseCommand, LoggerMixin): | ... | @@ -1646,7 +1646,7 @@ class Command(BaseCommand, LoggerMixin): |
1646 | try: | 1646 | try: |
1647 | channel, img_path, text_list = img_queue.get(block=False) | 1647 | channel, img_path, text_list = img_queue.get(block=False) |
1648 | except Exception as e: | 1648 | except Exception as e: |
1649 | self.online_log.info('{0} [img_2_ocr_1] [queue empty]'.format(self.log_base)) | 1649 | # self.online_log.info('{0} [img_2_ocr_1] [queue empty]'.format(self.log_base)) |
1650 | time.sleep(self.sleep_time_img_get) | 1650 | time.sleep(self.sleep_time_img_get) |
1651 | continue | 1651 | continue |
1652 | else: | 1652 | else: | ... | ... |
... | @@ -102,7 +102,7 @@ for db_setting in DATABASES.values(): | ... | @@ -102,7 +102,7 @@ for db_setting in DATABASES.values(): |
102 | 'driver': 'ODBC Driver 17 for SQL Server', | 102 | 'driver': 'ODBC Driver 17 for SQL Server', |
103 | 'extra_params': "odbc_cursortype=2" | 103 | 'extra_params': "odbc_cursortype=2" |
104 | } | 104 | } |
105 | db_setting['CONN_MAX_AGE'] = 60 | 105 | db_setting['CONN_MAX_AGE'] = 0 |
106 | # set this to False if you want to turn off pyodbc's connection pooling | 106 | # set this to False if you want to turn off pyodbc's connection pooling |
107 | DATABASE_CONNECTION_POOLING = True | 107 | DATABASE_CONNECTION_POOLING = True |
108 | 108 | ... | ... |
-
Please register or sign in to post a comment