common_helper/src/main/java/com/xiongyingqi/util/Log4jConfigurer.java
public static void initLogging(String location) throws FileNotFoundException {
        String resolvedLocation = SystemPropertyUtils.resolvePlaceholders(location);
        URL url = ResourceUtils.getURL(resolvedLocation);
        if (resolvedLocation.toLowerCase().endsWith(XML_FILE_EXTENSION)) {
            DOMConfigurator.configure(url);
        } else {
            PropertyConfigurator.configure(url);
        }
    }
public static void initLogging(String location) throws FileNotFoundException {
        String resolvedLocation = SystemPropertyUtils.resolvePlaceholders(location);
        URL url = ResourceUtils.getURL(resolvedLocation);
        if (resolvedLocation.toLowerCase().endsWith(XML_FILE_EXTENSION)) {
            DOMConfigurator.configure(url);
        } else {
            PropertyConfigurator.configure(url);
        }
    }
Initialize log4j from the given file location, with no config file refreshing.
Assumes an XML file in case of a ".xml" file extension, and a properties file
otherwise.

@param location the location of the config file: either a "classpath:" location
(e.g. "classpath:myLog4j.properties"), an absolute file URL
(e.g. "file:C:/log4j.properties), or a plain absolute path in the file system
(e.g. "C:/log4j.properties")
@throws java.io.FileNotFoundException if the location specifies an invalid file path