当前位置:   article > 正文

com.mchange.v2.resourcepool.CannotAcquireResourceException

com.mchange.v2.resourcepool.cannotacquireresourceexception: a resourcepool c
Exception in thread "main" java.sql.SQLException: Connections could not be acquired from the underlying database!

<pre name="code" class="html">Caused by: com.mchange.v2.resourcepool.CannotAcquireResourceException: A ResourcePool could not acquire a resource from its primary factory or source.


 

这是链接不到数据库,原因多种,我遇到一种,就是我的数据库没有设置密码,而我设置了密码去使用

  1. user=root
  2. password=123
  3. driverclass=com.mysql.jdbc.Driver
  4. jdbcurl=jdbc:mysql://localhost:3306/hibernate


后来改成无密码,则对上了

  1. user=root
  2. password=
  3. driverclass=com.mysql.jdbc.Driver
  4. jdbcurl=jdbc:mysql://localhost:3306/hibernate


声明:本文内容由网友自发贡献,不代表【wpsshop博客】立场,版权归原作者所有,本站不承担相应法律责任。如您发现有侵权的内容,请联系我们。转载请注明出处:https://www.wpsshop.cn/w/笔触狂放9/article/detail/627458
推荐阅读
相关标签
  

闽ICP备14008679号