jboss에서 slf4j 오류 해결 방안

1096 단어 slf4jJBoss5
jboss5는 다음과 같은 오류를 보고합니다
ERROR [stdERR] SLF4J: Class path contains multiple SLF4J bindings. ERROR [stdERR] SLF4J: Found binding in [vfszip:/home/ihrytsyuk/work/ml/jboss/common/lib/slf4j-jboss-logging.jar/org/slf4j/impl/StaticLoggerBinder.class] ERROR [stdERR] SLF4J: Found binding in [vfszip:/home/ihrytsyuk/work/ml-dev/out/exploded/eee.ear/lib/slf4j-log4j12-1.6.1.jar/org/slf4j/impl/StaticLoggerBinder.class]  ERROR [stdERR] SLF4J: See http://www.slf4j.org/codes.html#multiple_bindings for an explanation.
해결: jboss\server\default\deployers\jbossweb.deployer\META-INF\war-deployers-jboss-beans.xml 추가 org.slf4j, 이 패키지 필터링 (자신의 jboss 설치 경로에 따라)
 <!-- Allow for war local class loaders: in testing -->
   <bean name="WarClassLoaderDeployer" class="org.jboss.web.tomcat.service.deployers.WarClassLoaderDeployer">
      <property name="relativeOrder">-1</property>
	  <property name="filteredPackages">javax.servlet,org.apache.commons.logging,org.slf4j</property>       
   </bean>

좋은 웹페이지 즐겨찾기