调整连接池数量,最大设置为30个
This commit is contained in:
@@ -62,7 +62,7 @@ class DBConnectionManager:
|
||||
# 准备连接池配置
|
||||
pool_config = {
|
||||
'pool_name': 'wechat_robot_pool',
|
||||
'pool_size': 10, # 连接池大小
|
||||
'pool_size': 30, # 连接池大小
|
||||
'host': config.get('host', 'localhost'),
|
||||
'port': config.get('port', 3306),
|
||||
'user': config.get('user', 'root'),
|
||||
@@ -97,7 +97,7 @@ class DBConnectionManager:
|
||||
password=config.get('password', None),
|
||||
db=config.get('db', 0),
|
||||
decode_responses=config.get('decode_responses', True),
|
||||
max_connections=config.get('max_connections', 10)
|
||||
max_connections=config.get('max_connections', 30)
|
||||
)
|
||||
self.LOG.info("Redis连接池初始化成功")
|
||||
except Exception as e:
|
||||
|
||||
Reference in New Issue
Block a user