2 Replies Latest reply on Jan 24, 2015 4:20 AM by Mirek Sz

    JBOSS 7.1.1 Logging problem when change Java version

    Mirek Sz Newbie

      Hello,

       

      I have strange problem I use JBOSS 7.1.1 and my app is package in ear. When I run JBOSS on Oracle JDK 1.6.38 and under everything works great but 1.6.39 and above, also JDK 7 it change my logging level to DEBUG.

      I know that this is weird but maybe someone had similar problem.

      I repeat the problem on 3 computers java version 32 bit vs 64 dosen't matter

        • 1. Re: JBOSS 7.1.1 Logging problem when change Java version
          James Perkins Master

          Can you explain what you mean by it changes your logging level to DEBUG? Like all you see is debug messages.

           

          --

          James R. Perkins

          • 2. Re: Re: JBOSS 7.1.1 Logging problem when change Java version
            Mirek Sz Newbie

            The root logging level which I set to WARN change to DEBUG. After degugging jboss-logging subsystem problem is in

             

            org.apache.log4j.JBossLevelMapping.getPriorityFor(Level)

             

            the code

              public static Level getPriorityFor(java.util.logging.Level level) {
                    final Level p;
                    return (p = priorityMap.get(level)) == null ? DEFAULT_LOG4J_LEVEL : p;
                }
            
            

             

            the priorityMap is a IdentityHashMap and contains key "WARN"(and many others) but the input param "level" is also WARN (value from config) but is not the same object(different memory id) as WARN on map. From this code I find that map return null what means that takes DEFAULT_LOG4J_LEVEL which is a DEBUG :-(