ming yue created JGRP-1879:
------------------------------
Summary: log4j 2 suport error
Key: JGRP-1879
URL:
https://issues.jboss.org/browse/JGRP-1879
Project: JGroups
Issue Type: Bug
Affects Versions: 3.5, 3.4.4
Environment: jdk 7
Reporter: ming yue
Assignee: Bela Ban
LogFactory suport jdk log,log4j,log4j 2,bug useing
USE_JDK_LOGGER=isPropertySet(Global.USE_JDK_LOGGER);
IS_LOG4J_AVAILABLE=isAvailable("org.apache.log4j.Logger");
IS_LOG4J2_AVAILABLE=isAvailable("org.apache.logging.log4j.core.Logger");
initialize var flag,
the isAvailable function depend on ClassNotFoundException ,when useing log4j 2 Log4j 1.x
bridge, has org.apache.log4j.Logger class ,then exception is not ClassNotFoundException
,change isAvailable to:
protected static boolean isAvailable(String classname) {
try {
return Class.forName(classname) != null;
}
catch(Exception cnfe) {
return false;
}
}
--
This message was sent by Atlassian JIRA
(v6.3.1#6329)