Hazırda bekletme 3.5.3 JPA ile glassfish 3.0.1 üzerinde çalışıyorum;, hazırda bekletme ve glassfish ile log4j kullanarak 3.0.1
Netbeans 6.9.1 kurumsal projesi kullanıyorum; Ben gerekli tüm hazırda dosyaları eklendi ve her şey ... günlüğü dışında gayet
dokümanlar bu aşağıdaki (sadece günlük ilişkili kavanoz listelenmiştir) demek gibi proje sınıf yoluna eklenir:-slf4j-api-
: benziyor 1.5.8.jar-slf4j-log4j12-1.5.8.jar
-log4j-1.2.16.jar
-log4j.properties
Ayrıca, -Dlog4j.debug
JVM özelliğini kullanarak hata ayıklamayı da etkinleştirdim.
En kısa sürede ben sunucu günlüğüne bu olsun dağıtmak olarak: Ben bu düzeltirim nasıl
SEVERE: log4j:ERROR A "org.apache.log4j.ConsoleAppender" object is not assignable to a "org.apache.log4j.Appender" variable.
SEVERE: log4j:ERROR The class "org.apache.log4j.Appender" was loaded by
SEVERE: log4j:ERROR [EarLibClassLoader :
urlSet = [URLEntry : file:/C:/Users/Bogdan/Documents/NetBeansProjects/GwtCms/dist/gfdeploy/GwtCms/lib/antlr-2.7.6.jar, URLEntry : file:/C:/Users/Bogdan/Documents/NetBeansProjects/GwtCms/dist/gfdeploy/GwtCms/lib/commons-collections-3.1.jar, URLEntry : file:/C:/Users/Bogdan/Documents/NetBeansProjects/GwtCms/dist/gfdeploy/GwtCms/lib/dom4j-1.6.1.jar, URLEntry : file:/C:/Users/Bogdan/Documents/NetBeansProjects/GwtCms/dist/gfdeploy/GwtCms/lib/gwt-servlet.jar, URLEntry : file:/C:/Users/Bogdan/Documents/NetBeansProjects/GwtCms/dist/gfdeploy/GwtCms/lib/hibernate-jpa-2.0-api-1.0.0.Final.jar, URLEntry : file:/C:/Users/Bogdan/Documents/NetBeansProjects/GwtCms/dist/gfdeploy/GwtCms/lib/hibernate3.jar, URLEntry : file:/C:/Users/Bogdan/Documents/NetBeansProjects/GwtCms/dist/gfdeploy/GwtCms/lib/javassist-3.9.0.GA.jar, URLEntry : file:/C:/Users/Bogdan/Documents/NetBeansProjects/GwtCms/dist/gfdeploy/GwtCms/lib/jta-1.1.jar, URLEntry : file:/C:/Users/Bogdan/Documents/NetBeansProjects/GwtCms/dist/gfdeploy/GwtCms/lib/log4j-1.2.16.jar, URLEntry : file:/C:/Users/Bogdan/Documents/NetBeansProjects/GwtCms/dist/gfdeploy/GwtCms/lib/slf4j-api-1.5.8.jar, URLEntry : file:/C:/Users/Bogdan/Documents/NetBeansProjects/GwtCms/dist/gfdeploy/GwtCms/lib/slf4j-log4j12-1.5.8.jar]
doneCalled = false
Parent -> [email protected]
] whereas object of type
SEVERE: log4j:ERROR "org.apache.log4j.ConsoleAppender" was loaded by [EarLibClassLoader :
urlSet = [URLEntry : file:/C:/Users/Bogdan/Documents/NetBeansProjects/GwtCms/dist/gfdeploy/GwtCms/lib/antlr-2.7.6.jar, URLEntry : file:/C:/Users/Bogdan/Documents/NetBeansProjects/GwtCms/dist/gfdeploy/GwtCms/lib/commons-collections-3.1.jar, URLEntry : file:/C:/Users/Bogdan/Documents/NetBeansProjects/GwtCms/dist/gfdeploy/GwtCms/lib/dom4j-1.6.1.jar, URLEntry : file:/C:/Users/Bogdan/Documents/NetBeansProjects/GwtCms/dist/gfdeploy/GwtCms/lib/gwt-servlet.jar, URLEntry : file:/C:/Users/Bogdan/Documents/NetBeansProjects/GwtCms/dist/gfdeploy/GwtCms/lib/hibernate-jpa-2.0-api-1.0.0.Final.jar, URLEntry : file:/C:/Users/Bogdan/Documents/NetBeansProjects/GwtCms/dist/gfdeploy/GwtCms/lib/hibernate3.jar, URLEntry : file:/C:/Users/Bogdan/Documents/NetBeansProjects/GwtCms/dist/gfdeploy/GwtCms/lib/javassist-3.9.0.GA.jar, URLEntry : file:/C:/Users/Bogdan/Documents/NetBeansProjects/GwtCms/dist/gfdeploy/GwtCms/lib/jta-1.1.jar, URLEntry : file:/C:/Users/Bogdan/Documents/NetBeansProjects/GwtCms/dist/gfdeploy/GwtCms/lib/log4j-1.2.16.jar, URLEntry : file:/C:/Users/Bogdan/Documents/NetBeansProjects/GwtCms/dist/gfdeploy/GwtCms/lib/slf4j-api-1.5.8.jar, URLEntry : file:/C:/Users/Bogdan/Documents/NetBeansProjects/GwtCms/dist/gfdeploy/GwtCms/lib/slf4j-log4j12-1.5.8.jar]
doneCalled = false
Parent -> [email protected]
].
SEVERE: log4j:ERROR Could not instantiate appender named "stdout".
SEVERE: log4j:WARN No appenders could be found for logger (org.hibernate.cfg.annotations.Version).
SEVERE: log4j:WARN Please initialize the log4j system properly.
SEVERE: log4j:WARN See http://logging.apache.org/log4j/1.2/faq.html#noconfig for more info.
Herhangi bir fikir? Teşekkür ederim!
SEVERE: org/apache/log4j/Level
java.lang.NoClassDefFoundError: org/apache/log4j/Level
at org.slf4j.LoggerFactory.getSingleton(LoggerFactory.java:223)
at org.slf4j.LoggerFactory.bind(LoggerFactory.java:120)
at org.slf4j.LoggerFactory.performInitialization(LoggerFactory.java:111)
at org.slf4j.LoggerFactory.getILoggerFactory(LoggerFactory.java:269)
EDIT2: DÜZENLEME
Ben Tushar Tarkas önerildiği gibi projemden log4j kaldırmak için çalıştı ÇÖZÜM
Nedenini bilmiyorum, ama eğer ben log4j-1.2.16.jar dosyasını/domain/domain1/lib dosyasına kopyalayın.
EDIT3:
Pascal, burada GF dağıtır budur.
EnterpriseApplication1-ejb_jar >
.netbeans_automatic_build
.netbeans_update_resources
ejbs // classes for EJB
entities // classes for entities
log4j.properties
META-INF
EnterpriseApplication1-war_war >
index.jsp
META-INF
WEB-INF
META-INF
lib >
antlr-2.7.6.jar
commons-collections-3.1.jar
dom4j-1.6.1.jar
hibernate-jpa-2.0-api-1.0.0.Final.jar
hibernate3.jar
javassist-3.9.0.GA.jar
jta-1.1.jar
log4j-1.2.16.jar
slf4j-api-1.5.8.jar
slf4j-log4j12-1.5.8.jar
Log4j.jar'ın kaldırılması kesinlikle bir çözüm değildir. Ama tam olarak nasıl paketlediğini bilmek isterim. –
Pascal son düzenlemeye bakın :) – Bogdan
Neyse, hazırda bekletme + GF + NB hakkında bir eğitim yazdım. Ben hala GF3 ile log4j çalışması yapmanın daha iyi bir yolu ile ilgileniyorum. Öğretici burada bulunabilir: http://bogdantanaseit.blogspot.com/2010/08/hibernate-jpa-20-on-glassfish-v3-with.html – Bogdan