Proxool Provider unable to load JAXP configurator file: proxoolconf.xml
Proxool Provider unable to load JAXP configurator file: proxoolconf.xml
- log4j:WARN No appenders could be found for logger (org.hibernate.cfg.Environment).
- log4j:WARN Please initialize the log4j system properly.
- %%%% Error Creating SessionFactory %%%%
- org.hibernate.HibernateException: Proxool Provider unable to load JAXP configurator file: proxoolconf.xml
- at org.hibernate.connection.ProxoolConnectionProvider.configure(ProxoolConnectionProvider.java:125)
- at org.hibernate.connection.ConnectionProviderFactory.newConnectionProvider(ConnectionProviderFactory.java:124)
- at org.hibernate.connection.ConnectionProviderFactory.newConnectionProvider(ConnectionProviderFactory.java:56)
- at org.hibernate.cfg.SettingsFactory.createConnectionProvider(SettingsFactory.java:366)
- at org.hibernate.cfg.SettingsFactory.buildSettings(SettingsFactory.java:60)
- at org.hibernate.cfg.Configuration.buildSettings(Configuration.java:1881)
- at org.hibernate.cfg.Configuration.buildSessionFactory(Configuration.java:1174)
- at dao.HibernateSessionFactory.<clinit>(HibernateSessionFactory.java:31)
- at dao.BaseHibernateDAO.getSession(BaseHibernateDAO.java:13)
- at work.ConnMysql.main(ConnMysql.java:30)
- Caused by: org.logicalcobwebs.proxool.ProxoolException: Parsing failed.
- at org.logicalcobwebs.proxool.configuration.JAXPConfigurator.configure(JAXPConfigurator.java:91)
- at org.logicalcobwebs.proxool.configuration.JAXPConfigurator.configure(JAXPConfigurator.java:107)
- at org.hibernate.connection.ProxoolConnectionProvider.configure(ProxoolConnectionProvider.java:120)
- ... 9 more
- Caused by: org.logicalcobwebs.proxool.ProxoolException: Attempt to register duplicate pool called 'DBPool'
- at org.logicalcobwebs.proxool.configuration.XMLConfigurator.endElement(XMLConfigurator.java:198)
- at org.apache.xerces.parsers.AbstractSAXParser.endElement(Unknown Source)
- at org.apache.xerces.impl.XMLNSDocumentScannerImpl.scanEndElement(Unknown Source)
- at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl$FragmentContentDispatcher.dispatch(Unknown Source)
- at org.apache.xerces.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source)
- at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
- at org.apache.xerces.parsers.XML11Configuration.parse(Unknown Source)
- at org.apache.xerces.parsers.XMLParser.parse(Unknown Source)
- at org.apache.xerces.parsers.AbstractSAXParser.parse(Unknown Source)
- at javax.xml.parsers.SAXParser.parse(Unknown Source)
- at org.logicalcobwebs.proxool.configuration.JAXPConfigurator.configure(JAXPConfigurator.java:87)
- ... 11 more
- %%%% Error Creating SessionFactory %%%%
- org.hibernate.MappingException: Could not read mappings from resource: dao/Day.hbm.xml
- at org.hibernate.cfg.Configuration.addResource(Configuration.java:485)
- at org.hibernate.cfg.Configuration.parseMappingElement(Configuration.java:1465)
- at org.hibernate.cfg.Configuration.parseSessionFactory(Configuration.java:1433)
- at org.hibernate.cfg.Configuration.doConfigure(Configuration.java:1414)
- at org.hibernate.cfg.Configuration.doConfigure(Configuration.java:1390)
- at org.hibernate.cfg.Configuration.configure(Configuration.java:1310)
- at dao.HibernateSessionFactory.rebuildSessionFactory(HibernateSessionFactory.java:69)
- at dao.HibernateSessionFactory.getSession(HibernateSessionFactory.java:53)
- at dao.BaseHibernateDAO.getSession(BaseHibernateDAO.java:13)
- at work.ConnMysql.main(ConnMysql.java:30)
- Caused by: org.hibernate.DuplicateMappingException: Duplicate class/entity mapping dao.Day
- at org.hibernate.cfg.Mappings.addClass(Mappings.java:118)
- at org.hibernate.cfg.HbmBinder.bindRoot(HbmBinder.java:154)
- at org.hibernate.cfg.Configuration.add(Configuration.java:386)
- at org.hibernate.cfg.Configuration.addInputStream(Configuration.java:427)
- at org.hibernate.cfg.Configuration.addResource(Configuration.java:482)
- ... 9 more
- Exception in thread "main" java.lang.NullPointerException
- at work.ConnMysql.main(ConnMysql.java:30)
以上是在配置proxool连接池的时候遇到的问题。
以下是从http://hi.baidu.com/9prior/blog/item/ad3565cab53e214ef31fe7a1.html转载来的:
因为是在原本的工程上添加一个hibernate的插入测试,我不知道原来工程中已经有一个类是用来开连接池的,一启动服务器就可用自动打开。而我啥啥的在jsp页面里面重复的写了SessionFactory sf = new Configuration().configure()
.buildSessionFactory();
这些,导致重新打开连接,慢不用说,还报出了错。
应该利用那个已写好的类来操作数据库的
以下附录在晚上找到的其他相关解决方式;
近日使用hibernate+proxool连接池时,总是报异常:
Proxool Provider unable to load JAXP configurator file: proxool.xml
org.logicalcobwebs.proxool.ProxoolException: Parsing failed.
我在网上查了N多的文章,总是解决不了问题.最后把web.xml中的以下配置删除,竟然好了,不知是什么原因.有知道原因的朋友,请留言! 先谢了!
<servlet>
<servlet-name>ServletConfigurator</servlet-name>
<servlet-class>
org.logicalcobwebs.proxool.configuration.ServletConfigurator
</servlet-class>
<init-param>
<param-name>xmlFile</param-name>
<param-value>WEB-INF/classes/proxool.xml</param-value>
</init-param>
<load-on-startup>1</load-on-startup>
</servlet>
补充:
解决hibernate和jdbc不能同时使用proxool的问题:
<property name="hibernate.proxool.xml">proxool.xml</property>
<property name="dialect">org.hibernate.dialect.MySQLDialect</property>
<property name="hibernate.proxool.existing_pool">true</property> //主要是加上此行既可
<property name="show_sql">true</property>
==============================================================================
我就是通过删除build语句,就修改成功了。。(⊙﹏⊙b汗,折腾了一晚上就因为这一句话。。。)
当然,这也是和C3P0一个区别吧。
Proxool Provider unable to load JAXP configurator file: proxoolconf.xml的更多相关文章
- 连接池报错 Proxool Provider unable to load JAXP configurator file: proxool.xml
上篇博文讲到简易配置 proxool 连接池:http://www.cnblogs.com/linnuo/p/7232380.html 由于把说明注释留在了 proxool.xml 配置文件里导致配置 ...
- 报错:Unable to load configuration. - action - file:/E:/apache-tomcat-8.0.37/webapps/20161102-struts2-3/WEB-INF/classes/struts.xml:11:73
第一种报错: 严重: Exception starting filter struts2Unable to load configuration. - action - file:/E:/apache ...
- 出现错误:Unable to load configuration. - action - file:/E:/Java/Tomcat7.0/apache-tomcat-7.0.68-windows-x64/apache-tomcat-7.0.68/webapps/SSH2Integrate/WEB-INF/classes/struts.xml:8:43
严重: Exception starting filter struts2 Unable to load configuration. - action - file:/E:/Java/Tomcat7 ...
- Unable to load configuration. - action - file:/F:/apache-tomcat-8.0.30/webapps/test1Struts2/WEB-INF/classes/struts.xml:11:71
Unable to load configuration. - action - file:/F:/apache-tomcat-8.0.30/webapps/test1Struts2/WEB-INF/ ...
- Caused by: Unable to load configuration. - action - file:/C:/apache-tomcat-7.0.70/webapps/Structs/WEB-INF/classes/struts.xml:7:72 at com.opensymphony.xwork2.config.ConfigurationManager.getConfigurati
Unable to load configuration. - action - file:/C:/apache-tomcat-7.0.70/webapps/Structs/WEB-INF/class ...
- CodeIgniter问题:Unable to load the requested file: .php
调试时出现 Unable to load the requested file: .php, 后来排查到是模板渲染的问题,view函数的参数没接收到,修改后就好了.
- Unable to load configuration. - action - file:/C:/Program%20Files/Apache%20Software%20Foundation/Tomcat%209.0/webapps/Teacher04/WEB-INF/classes/struts.xml:9:54
发布一个struts2项目的时候tomcat显示下面这个错误,我的本能感觉就是我的struts.xml或者web.xml写错了,可是我字母找都没发现,于是百度一番,可是我对那些人的回答表示怀疑,感觉应 ...
- Struts2配置拦截器自定义栈时抛异常:Unable to load configuration. - interceptor-ref - file:/D:/tomcat_install/webapps/crm/WEB-INF/classes/struts.xml
代码如下: <interceptors> <!-- 注册自定义拦截器 --> <interceptor name="LoginInterceptor&qu ...
- Struts2中的Unable to load configuration错误的分析与解决方法
当我们遇到 Unable to load configuration. 这样的错误时,可以根据具体的错误提示找出错误的原因. Unable to load configuration. - inter ...
随机推荐
- 树莓派视频监控 —— 使用 mjpg
下载到树莓派本地: $ wget https://github.com/jacksonliam/mjpg-streamer/archive/master.zip $ unzip master.zip ...
- 2017-2018-1 20179215《Linux内核原理与分析》第十二周作业
Sql注入基础原理介绍 分组:和20179205王雅哲共同完成实验 一.实验说明 1.1 sql注入 SQL注入攻击通过构建特殊的输入作为参数传入Web应用程序,而这些输入大都是SQL语法里的一些组 ...
- Linux命令学习(22):ss命令
版权声明 更新:2017-05-20 博主:LuckyAlan 联系:liuwenvip163@163.com 声明:吃水不忘挖井人,转载请注明出处! 1 文章介绍 本文介绍了Linux下面的ss命令 ...
- poj2411 Mondriaan's Dream[简单状压dp]
$11*11$格子板上铺$1*2$地砖方案.以前做过?权当复习算了,毕竟以前学都是浅尝辄止的..常规题,注意两个条件:上一行铺竖着的则这一行同一位一定要铺上竖的,这一行单独铺横的要求枚举集合中出现连续 ...
- bzoj 3887: Grass Cownoisseur Tarjan+Topusort
题目: 给一个有向图,然后选一条路径起点终点都为1的路径出来,有一次机会可以沿某条边逆方向走,问最多有多少个点可以被经过?(一个点在路径中无论出现多少正整数次对答案的贡献均为1) 题解: 首先考虑简单 ...
- 杂项之python利用pycrypto实现RSA
杂项之python利用pycrypto实现RSA 本节内容 pycrypto模块简介 RSA的公私钥生成 RSA使用公钥加密数据 RSA使用私钥解密密文 破解博客园登陆 pycrypto模块简介 py ...
- [Unity3D]关于U3D贴图格式压缩
http://blog.sina.com.cn/s/blog_5b6cb9500102vi6i.html 因为有不少人都问过我压缩格式的问题,今天飞哥又重新提醒了一次.整理一下发个贴,以供大家查阅和讨 ...
- 第11篇 PSR-0 规范
Mandatory A fully-qualified namespace and class must have the following structure \<Vendor Name&g ...
- 【Linux网络编程】基于TCP流 I/O多路转接(poll) 的高性能http服务器
服务器比较简陋,为了学习poll的使用,只向客户端回写一条html语句.启动服务器后,浏览器发起请求,服务端向浏览器写回html,响应字符串,然后可以看到,浏览器解析并显示 Hello Poll!. ...
- eclipse -- propedit 安装.
SSH 项目中.用到国际化文件,Message.properties 但里面的文本都是 unicode 格式的,用起来不谁.而且也不想通过其它工具转码来使用. 可以通过安装 eclipse 的 pro ...