当前位置: 代码迷 >> Java Web开发 >> 请教一个用Hibernate+proxool的有关问题
  详细解决方案

请教一个用Hibernate+proxool的有关问题

热度:20   发布时间:2016-04-17 14:59:51.0
请问一个用Hibernate+proxool的问题
我在用Myeclipse创建Hbm.xml和POJO的时候,老是发生这样的错误
!MESSAGE   An   internal   error   occurred   during:   "Generating   Artifacts ".
!STACK   0
org.hibernate.HibernateException:   Proxool   Provider   unable   to   load   JAXP   configurator   file:   proxool.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:1877)
at   com.genuitec.eclipse.hibernate.wizards.MEJDBCMetaDataConfiguration.readFromJDBC(MEJDBCMetaDataConfiguration.java:73)
at   com.genuitec.eclipse.hibernate.wizards.GenerateArtifactsJob$6.execute(GenerateArtifactsJob.java:529)
at   org.hibernate.console.execution.DefaultExecutionContext.execute(DefaultExecutionContext.java:35)
at   org.hibernate.console.ConsoleConfiguration.execute(ConsoleConfiguration.java:72)
at   com.genuitec.eclipse.hibernate.wizards.GenerateArtifactsJob.buildConfiguration(GenerateArtifactsJob.java:524)
at   com.genuitec.eclipse.hibernate.wizards.GenerateArtifactsJob.run(GenerateArtifactsJob.java:296)
at   org.eclipse.core.internal.jobs.Worker.run(Worker.java:58)
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)
...   12   more
Caused   by:   org.logicalcobwebs.proxool.ProxoolException:   Couldn 't   load   class   com.microsoft.jdbc.sqlserver.SQLServerDriver
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   org.apache.xerces.jaxp.SAXParserImpl$JAXPSAXParser.parse(Unknown   Source)
at   org.apache.xerces.jaxp.SAXParserImpl.parse(Unknown   Source)
at   org.logicalcobwebs.proxool.configuration.JAXPConfigurator.configure(JAXPConfigurator.java:87)
...   14   more

Proxool.xml的配置是
<?xml   version= "1.0 "   encoding= "UTF-8 "?>
<something-else-entirely>
<proxool>
<alias> cmsProxool </alias> <!--连接池的别名-->
<driver-url> jdbc:microsoft:sqlserver://localhost:1433;databaseName=cms;SelectMethod=cursor </driver-url>
  相关解决方案