如果超出max-connections(connection的最大值)的设置值的情况下,将会临时使用可以使用的连接(overConnection)。
获取overConnection的时候,会在一定的时间(connection-wait-time)内待机用于判断通常的连接是否可以再次使用。
如果在一定的时间内,没能获取可再次使用的连接的情况下,将作为overConnection获取连接。
超过max-connections + max-overflow-connections(overConnection的最大值数) 的情况下,
“system.log”以及“exception.log”将输出以下错误。
------------------------------
Connection pool is full.
Can't allocate connection.
------------------------------
此外,如果因max-connections的设置值导致处理延迟,则可能是max-connections的设置不正确 (设置不足)或快要达到超出设置值的状态、或是运行环境的原因造成的。
例如,数据库的处理能力低、响应速度慢时,连接将持续处于使用中的状态,结果可能导致超出max-connections的设置值。
因此,要合理设置max-connections则必须在了解运行环境的处理能力、运行环境的情况以及连接情况之后,设置符合运行环境的值。
※可以将使用Resin的Resin Admin功能,作为某种程度上掌握运行环境中的应用程序情况的手段。
请参阅以下开发者博客中记载的Resin Admin的设置方法。
・intra-mart Advent Calendar 2013 第9天:Resin Admin的介绍
https://dev.intra-mart.jp/intra-mart_advent_calendar_2013_9resin_admin/
-- 适用对象 ----------------------------------------------------------------
iAP/Accel Platform/所有更新版本
--------------------------------------------------------------------------------
FAQID:419
如果超出resin-web.xml中设置的max-connections的值时,处理会变慢吗?