0 Replies Latest reply on Feb 14, 2019 9:59 AM by fstarred

    logging on separate configuration between REST and EJB modules

    fstarred

      My purpose is to separate log4j configuration between REST and EJB in a JEE 5 web application (JBoss 5.1).

       

      For REST module, I use ServletContextListener interface:

      public void contextInitialized(ServletContextEvent sce) { 
          PropertyConfigurator.configure("rest-log.ini");
      }

      for EJB module, I'm using StartupBeanManagement interface:

      @Override public void start() throws Exception { 
          logger
      .info("starting configuration bean");
          configureLog
      ("ejb-log.ini"));
      }

      However, if both modules are deployed on the same container, I can see log only only on dedicated REST log.

      How I can separate logging between modules?