閱讀210 返回首頁    go 阿裏雲 go 技術社區[雲棲]


Couldn't get connection because we are at maximum connection count (150/150) and there are none 異常解決

係統運行一段時間後發現出現這樣的異常:

Couldn't get connection because we are at maximum connection count (150/150) and there are none available


解決方案:

1、修改連接池的最大的連接數:

<maximum-connection-count>1000</maximum-connection-count>

2、更改hibernate.connection.release_mode配置的模式為:after_transaction
Hibernate 的連接釋放模式:hibernate.connection.release_mode 有三個選擇:after_statement/after_transaction/on_close,默認的是on_close所以,這裏要改成after_transaction

<prop key="hibernate.connection.release_mode">after_transaction</prop> 


最後更新:2017-04-03 12:53:45

  上一篇:go hi3531串口波特率計算
  下一篇:go 軟件需求