hibernate和tomcat警告错误

hibernate和tomcat警告错误,hibernate,tomcat,Hibernate,Tomcat,如果我在登录页面上登录,我会得到以下错误/警告 May 04, 2014 11:44:56 AM org.apache.catalina.core.AprLifecycleListener init INFO: The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.pat

如果我在登录页面上登录,我会得到以下错误/警告

    May 04, 2014 11:44:56 AM org.apache.catalina.core.AprLifecycleListener init
INFO: The APR based Apache Tomcat Native library which allows optimal performance in production environments was not found on the java.library.path: C:\Program Files\Java\jdk1.7.0_51\bin;C:\Windows\Sun\Java\bin;C:\Windows\system32;C:\Windows;C:/Program Files/Java/jdk1.7.0_51/bin/../jre/bin/server;C:/Program Files/Java/jdk1.7.0_51/bin/../jre/bin;C:/Program Files/Java/jdk1.7.0_51/bin/../jre/lib/amd64;C:\Program Files (x86)\NVIDIA Corporation\PhysX\Common;C:\Program Files\Common Files\Microsoft Shared\Windows Live;C:\Program Files (x86)\Common Files\Microsoft Shared\Windows Live;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Program Files\Intel\WiFi\bin\;C:\Program Files\Common Files\Intel\WirelessCommon\;C:\Program Files (x86)\Common Files\Reallusion\CamSuite;C:\Program Files (x86)\Windows Live\Shared;C:\Program Files (x86)\MySQL\MySQL Utilities 1.3.6\;C:\Ergin for Java\maven311\bin;C:\Program Files\Microsoft SQL Server\110\Tools\Binn\;C:\Program Files\Microsoft\Web Platform Installer\;C:\Program Files (x86)\Microsoft ASP.NET\ASP.NET Web Pages\v1.0\;C:\Program Files (x86)\Windows Kits\8.0\Windows Performance Toolkit\;C:\Program Files (x86)\GTK2-Runtime\lib;C:\Program Files\Microsoft SQL Server\110\DTS\Binn\;C:\Program Files (x86)\Microsoft SQL Server\110\Tools\Binn\;C:\Program Files (x86)\Microsoft SQL Server\110\Tools\Binn\ManagementStudio\;C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE\PrivateAssemblies\;C:\Program Files (x86)\Microsoft SQL Server\110\DTS\Binn\;C:\Program Files\Intel\WiFi\bin\;C:\Program Files\Common Files\Intel\WirelessCommon\;C:\Ergin for Java\eclipse;;.
May 04, 2014 11:44:56 AM org.apache.tomcat.util.digester.SetPropertiesRule begin
WARNING: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'source' to 'org.eclipse.jst.jee.server:proje' did not find a matching property.
May 04, 2014 11:44:56 AM org.apache.coyote.AbstractProtocol init
INFO: Initializing ProtocolHandler ["http-bio-8080"]
May 04, 2014 11:44:56 AM org.apache.coyote.AbstractProtocol init
INFO: Initializing ProtocolHandler ["ajp-bio-8009"]
May 04, 2014 11:44:56 AM org.apache.catalina.startup.Catalina load
INFO: Initialization processed in 819 ms
May 04, 2014 11:44:56 AM org.apache.catalina.core.StandardService startInternal
INFO: Starting service Catalina
May 04, 2014 11:44:56 AM org.apache.catalina.core.StandardEngine startInternal
INFO: Starting Servlet Engine: Apache Tomcat/7.0.50
May 04, 2014 11:44:57 AM org.apache.catalina.loader.WebappClassLoader validateJarFile
INFO: validateJarFile(C:\Ergin for Java\Workspace\.metadata\.plugins\org.eclipse.wst.server.core\tmp1\wtpwebapps\proje\WEB-INF\lib\javax.servlet-api-3.0.1.jar) - jar not loaded. See Servlet Spec 3.0, section 10.7.2. Offending class: javax/servlet/Servlet.class
SLF4J: Failed to load class "org.slf4j.impl.StaticLoggerBinder".
SLF4J: Defaulting to no-operation (NOP) logger implementation
SLF4J: See http://www.slf4j.org/codes.html#StaticLoggerBinder for further details.
May 04, 2014 11:44:59 AM org.apache.catalina.core.ApplicationContext log
INFO: Initializing Shiro environment
May 04, 2014 11:45:00 AM com.sun.faces.config.ConfigureListener contextInitialized
INFO: Initializing Mojarra 2.2.2 ( 20130809-1625 https://svn.java.net/svn/mojarra~svn/tags/2.2.2@12376) for context '/proje'
May 04, 2014 11:45:01 AM com.sun.faces.spi.InjectionProviderFactory createInstance
INFO: JSF1048: PostConstruct/PreDestroy annotations present.  ManagedBeans methods marked with these annotations will have said annotations processed.
May 04, 2014 11:45:02 AM org.primefaces.webapp.PostConstructApplicationEventListener processEvent
INFO: Running on PrimeFaces 4.0
May 04, 2014 11:45:02 AM org.apache.coyote.AbstractProtocol start
INFO: Starting ProtocolHandler ["http-bio-8080"]
May 04, 2014 11:45:02 AM org.apache.coyote.AbstractProtocol start
INFO: Starting ProtocolHandler ["ajp-bio-8009"]
May 04, 2014 11:45:02 AM org.apache.catalina.startup.Catalina start
INFO: Server startup in 5762 ms
May 04, 2014 11:45:08 AM org.hibernate.annotations.common.reflection.java.JavaReflectionManager <clinit>
INFO: HCANN000001: Hibernate Commons Annotations {4.0.4.Final}
May 04, 2014 11:45:08 AM org.hibernate.Version logVersion
INFO: HHH000412: Hibernate Core {4.3.5.Final}
May 04, 2014 11:45:08 AM org.hibernate.cfg.Environment <clinit>
INFO: HHH000206: hibernate.properties not found
May 04, 2014 11:45:08 AM org.hibernate.cfg.Environment buildBytecodeProvider
INFO: HHH000021: Bytecode provider name : javassist
May 04, 2014 11:45:08 AM org.hibernate.cfg.Configuration configure
INFO: HHH000043: Configuring from resource: /hibernate.cfg.xml
May 04, 2014 11:45:08 AM org.hibernate.cfg.Configuration getConfigurationInputStream
INFO: HHH000040: Configuration resource: /hibernate.cfg.xml
May 04, 2014 11:45:08 AM org.hibernate.cfg.Configuration addResource
INFO: HHH000221: Reading mappings from resource: com/db/Tables/Duyurular.hbm.xml
May 04, 2014 11:45:08 AM org.hibernate.cfg.Configuration addResource
INFO: HHH000221: Reading mappings from resource: com/db/Tables/Gorevler.hbm.xml
May 04, 2014 11:45:09 AM org.hibernate.cfg.Configuration addResource
INFO: HHH000221: Reading mappings from resource: com/db/Tables/Kategoriler.hbm.xml
May 04, 2014 11:45:09 AM org.hibernate.cfg.Configuration addResource
INFO: HHH000221: Reading mappings from resource: com/db/Tables/Kullanicilar.hbm.xml
May 04, 2014 11:45:09 AM org.hibernate.cfg.Configuration addResource
INFO: HHH000221: Reading mappings from resource: com/db/Tables/MesajDefteri.hbm.xml
May 04, 2014 11:45:09 AM org.hibernate.cfg.Configuration addResource
INFO: HHH000221: Reading mappings from resource: com/db/Tables/Odalar.hbm.xml
May 04, 2014 11:45:09 AM org.hibernate.cfg.Configuration addResource
INFO: HHH000221: Reading mappings from resource: com/db/Tables/OdaninOzellikleri.hbm.xml
May 04, 2014 11:45:09 AM org.hibernate.cfg.Configuration addResource
INFO: HHH000221: Reading mappings from resource: com/db/Tables/OdaOzellikleri.hbm.xml
May 04, 2014 11:45:09 AM org.hibernate.cfg.Configuration addResource
INFO: HHH000221: Reading mappings from resource: com/db/Tables/OdaResimleri.hbm.xml
May 04, 2014 11:45:09 AM org.hibernate.cfg.Configuration addResource
INFO: HHH000221: Reading mappings from resource: com/db/Tables/Odemeler.hbm.xml
May 04, 2014 11:45:09 AM org.hibernate.cfg.Configuration addResource
INFO: HHH000221: Reading mappings from resource: com/db/Tables/Ogrenciler.hbm.xml
May 04, 2014 11:45:09 AM org.hibernate.cfg.Configuration addResource
INFO: HHH000221: Reading mappings from resource: com/db/Tables/OgrenciOdasi.hbm.xml
May 04, 2014 11:45:09 AM org.hibernate.cfg.Configuration addResource
INFO: HHH000221: Reading mappings from resource: com/db/Tables/Sikayetler.hbm.xml
May 04, 2014 11:45:09 AM org.hibernate.cfg.Configuration addResource
INFO: HHH000221: Reading mappings from resource: com/db/Tables/Yetkiler.hbm.xml
May 04, 2014 11:45:09 AM org.hibernate.cfg.Configuration addResource
INFO: HHH000221: Reading mappings from resource: com/db/Tables/ZiyaretciDefteri.hbm.xml
May 04, 2014 11:45:09 AM org.hibernate.cfg.Configuration addResource
INFO: HHH000221: Reading mappings from resource: com/db/Tables/YokUniversiteler.hbm.xml
May 04, 2014 11:45:09 AM org.hibernate.cfg.Configuration addResource
INFO: HHH000221: Reading mappings from resource: com/db/Tables/YokFakulteler.hbm.xml
May 04, 2014 11:45:09 AM org.hibernate.cfg.Configuration addResource
INFO: HHH000221: Reading mappings from resource: com/db/Tables/YokBolumler.hbm.xml
May 04, 2014 11:45:09 AM org.hibernate.cfg.Configuration doConfigure
INFO: HHH000041: Configured SessionFactory: 
May 04, 2014 11:45:09 AM org.hibernate.engine.jdbc.connections.internal.DriverManagerConnectionProviderImpl configure
WARN: HHH000402: Using Hibernate built-in connection pool (not for production use!)
May 04, 2014 11:45:09 AM org.hibernate.engine.jdbc.connections.internal.DriverManagerConnectionProviderImpl buildCreator
INFO: HHH000401: using driver [com.mysql.jdbc.Driver] at URL [jdbc:mysql://localhost:3306/db]
May 04, 2014 11:45:09 AM org.hibernate.engine.jdbc.connections.internal.DriverManagerConnectionProviderImpl buildCreator
INFO: HHH000046: Connection properties: {user=root, password=****}
May 04, 2014 11:45:09 AM org.hibernate.engine.jdbc.connections.internal.DriverManagerConnectionProviderImpl buildCreator
INFO: HHH000006: Autocommit mode: false
May 04, 2014 11:45:09 AM org.hibernate.engine.jdbc.connections.internal.DriverManagerConnectionProviderImpl configure
INFO: HHH000115: Hibernate connection pool size: 10 (min=1)
May 04, 2014 11:45:09 AM org.hibernate.dialect.Dialect <init>
INFO: HHH000400: Using dialect: org.hibernate.dialect.MySQL5Dialect
May 04, 2014 11:45:09 AM org.hibernate.engine.transaction.internal.TransactionFactoryInitiator initiateService
INFO: HHH000399: Using default transaction strategy (direct JDBC transactions)
May 04, 2014 11:45:09 AM org.hibernate.hql.internal.ast.ASTQueryTranslatorFactory <init>
INFO: HHH000397: Using ASTQueryTranslatorFactory
hibernate.cfg.xml


com.mysql.jdbc.Driver
根
jdbc:mysql://localhost:3306/db
根
线
10
符合事实的
我尝试了一些解决办法,但对我来说不起作用。 他们是,

  • 我更改了hibernate.cfg.xml名称空间(您可以在cfg.xml的源代码中看到上面的内容)

  • 我选中了tomcat的服务器选项-将模块上下文发布为分离 XML文件

提前感谢您的帮助!
E.D.

您到底想解决什么问题?第一个警告与Tomcat的
server.xml
有关。第二个警告是因为您没有设置连接池,所以Hibernate正在抱怨。配置文件的名称空间与此有什么关系?大多数配置文件都遇到了cfg.xml名称空间错误。所以我想修复。这是我第二次尝试的解决方案。你的解决方案是什么?我该怎么办?也许开始吧。谢谢!左一。警告:[SetPropertiesRule]{Server/Service/Engine/Host/Context}将属性“source”设置为“org.eclipse.jst.jee.Server:proje”未找到匹配的属性。你对他有什么不同于我的解决办法吗?
WARNING: [SetPropertiesRule]{Server/Service/Engine/Host/Context} Setting property 'source' to 'org.eclipse.jst.jee.server:proje' did not find a matching property.

WARN: HHH000402: Using Hibernate built-in connection pool (not for production use!)
  <?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE hibernate-configuration PUBLIC "-//Hibernate/Hibernate Configuration DTD 3.0//EN"
                                         "http://www.hibernate.org/dtd/hibernate-configuration-3.0.dtd">
<hibernate-configuration>
    <session-factory name="">
        <property name="hibernate.connection.driver_class">com.mysql.jdbc.Driver</property>
        <property name="hibernate.connection.password">root</property>
        <property name="hibernate.connection.url">jdbc:mysql://localhost:3306/db</property>
        <property name="hibernate.connection.username">root</property>
        <property name="current_session_context_class">thread</property>
        <property name="connection.pool_size">10</property> 
        <property name="show_sql">true</property>
        <--mapping resources-->
    </session-factory>
</hibernate-configuration>