有没有人在运行 subdag 时在心跳阶段遇到“抱歉,已经有太多客户”错误?
[2017-11-22 08:21:23,747] {jobs.py:2136} 错误 - 尝试心跳时出现异常!休眠 5.0s Traceback(最近一次调用最后):文件“/usr/local/lib/python2.7/site-packages/airflow/jobs.py”,第 2131 行,在 _execute self.heartbeat() 文件“/usr /local/lib/python2.7/site-packages/airflow/jobs.py",第 180 行,在 heartbeat job = session.query(BaseJob).filter(BaseJob.id == self.id).first() 文件中“/usr/local/lib/python2.7/site-packages/sqlalchemy/orm/query.py”,第 2755 行,在第一个 ret = list(self[0:1]) 文件中“/usr/local/lib/ python2.7/site-packages/sqlalchemy/orm/query.py”,第 2547 行,在getitem 返回列表(res)文件“/usr/local/lib/python2.7/site-packages/sqlalchemy/orm/query. py",第 2855 行,在iter中 返回self._execute_and_instances(上下文)文件“/usr/local/lib/python2.7/site-packages/sqlalchemy/orm/query.py”,第2876行,在_execute_and_instances close_with_result=True)文件“/usr/local/lib /python2.7/site-packages/sqlalchemy/orm/query.py”,第 2885 行,在 _get_bind_args **kw 文件“/usr/local/lib/python2.7/site-packages/sqlalchemy/orm/query.py ",第 2867 行,_connection_from_session conn = self.session.connection(**kw) 文件 "/usr/local/lib/python2.7/site-packages/sqlalchemy/orm/session.py",第 998 行,在连接中execution_options=execution_options)文件“/usr/local/lib/python2.7/site-packages/sqlalchemy/orm/session.py”,第 1003 行,_connection_for_bind 引擎,execution_options)文件“/usr/local/lib/python2.7/site-packages/sqlalchemy/orm/session.py”,第 403 行,在 _connection_for_bind conn = bind.contextual_connect() 文件“/usr/local/lib/python2.7/site-packages/sqlalchemy/engine/base. py”,第 2112 行,在 contextual_connect self._wrap_pool_connect(self.pool.connect, None) 中,文件“/usr/local/lib/python2.7/site-packages/sqlalchemy/engine/base.py”,第 2151 行,在 _wrap_pool_connect e、方言、自我)文件“/usr/local/lib/python2.7/site-packages/sqlalchemy/engine/base.py”,第 1465 行,在 _handle_dbapi_exception_noconnection exc_info 文件“/usr/local/lib/python2 .7/site-packages/sqlalchemy/util/compat.py”,第 203 行,在 raise_from_cause reraise(类型(异常),异常,tb=exc_tb,cause=cause)文件“/usr/local/lib/python2.7 /site-packages/sqlalchemy/engine/base.py”,第 2147 行,在 _wrap_pool_connect 返回 fn() 文件“/usr/local/lib/python2.7/site-packages/sqlalchemy/pool.py”,第 387 行,在连接中返回 _ConnectionFairy._checkout(self) 文件“ /usr/local/lib/python2.7/site-packages/sqlalchemy/pool.py”,第 766 行,在 _checkout 仙女 = _ConnectionRecord.checkout(pool) 文件“/usr/local/lib/python2.7/site- packages/sqlalchemy/pool.py”,第 516 行,在结帐中 rec = pool._do_get() 文件“/usr/local/lib/python2.7/site-packages/sqlalchemy/pool.py”,第 1229 行,在 _do_get返回 self._create_connection() 文件“/usr/local/lib/python2.7/site-packages/sqlalchemy/pool.py”,第 333 行,在 _create_connection 返回 _ConnectionRecord(self) 文件“/usr/local/lib/python2 .7/site-packages/sqlalchemy/pool.py",第 461 行,在初始化 自我。连接(first_connect_check=True)文件“/usr/local/lib/python2.7/site-packages/sqlalchemy/pool.py”,第 651 行,在 __connect 连接 = pool._invoke_creator(self) 文件“/usr/local/ lib/python2.7/site-packages/sqlalchemy/engine/strategies.py”,第 105 行,在连接中返回 dialect.connect(*cargs, **cparams) 文件“/usr/local/lib/python2.7/site -packages/sqlalchemy/engine/default.py”,第 393 行,在连接中返回 self.dbapi.connect(*cargs, **cparams) 文件“/usr/local/lib/python2.7/site-packages/psycopg2/ __init .py",第 130 行,在连接 conn = _connect(dsn, connection_factory=connection_factory, **kwasync) OperationalError: (psycopg2.OperationalError) FATAL: 抱歉,已经有太多客户端
从airflow.cfg:在airflow.cfg:
sql_alchemy_pool_size = 100
sql_alchemy_pool_recycle = 3600
这个问题有已知的解决方案吗?我正在使用带 LocalExecutor 的气流 1.8.2。