code: public static void reloadAndWatch(final String configFile, final long delay) {
          long watchDelay = delay == 0 ? Log4jUtils.DEFAULT_WATCH_DELAY : delay;
          if (configFile != null) {
  
              if (configFile.endsWith(XML_FILE_EXENSION)) {
                  DOMConfigurator.configureAndWatch(configFile, watchDelay);
              } else
                  PropertyConfigurator.configureAndWatch(configFile, watchDelay);
  
          }
          if (logger.isInfoEnabled()) {
              logger.info("Reloads and watches log4j configuration: " + configFile);
          }
      }
docs: (Re)Loads the config file using {@link DOMConfigurator} for {@code .xml} files and {@link PropertyConfigurator} for {@code .proeprties} files.
  Reloads the file automatically when changed.
  
  @param configFile log4j configuration file, {@code .properties} or {@code .xml}
  @param delay number of milliseconds between checks of changes in the config file, defaults to {@link Log4jUtils#DEFAULT_WATCH_DELAY} if set to 0