现在我在使用hibernate查询时遇到了关于c3p0的问题。
例外是:
Caused by: java.lang.RuntimeException: [c3p0 bug] Only brand new IdentityTokenized's, with their identities just set, should be registered!!!
at com.mchange.v2.c3p0.C3P0Registry.register(C3P0Registry.java:103)
at com.mchange.v2.c3p0.DriverManagerDataSource.<init>(DriverManagerDataSource.java:74)
at com.mchange.v2.c3p0.DataSources.unpooledDataSource(DataSources.java:128)
at org.hibernate.connection.C3P0ConnectionProvider.configure(C3P0ConnectionProvider.java:96)
... 22 more
我无法从谷歌找到任何有用的信息,是否有任何伙伴知道原因?谢谢!
BTW:我的env是c3p0 0.9.0和hibernate 3.3
答案 0 :(得分:2)
是C3P0错误。我建议将C3P0升级到最新版本(目前为0.9.1.2,http://sourceforge.net/projects/c3p0/files/c3p0-bin/)。