Logging Outputs Incorrect Line Numbers in JBoss

Solution Verified - Updated -

Issue

  • When logging using the %L in the PatternLayout configuration in the $JBOSS_HOME/server/$PROFILE/conf/jboss-log4j.xml like

    <layout class="org.apache.log4j.PatternLayout">
      <param name="ConversionPattern" value="%d %-5p [%c:%L] (%t) %m%n"/>
    </layout>
    

The line numbers listed are incorrect:

2010-09-21 11:32:23,380 INFO [org.jboss.web.WebService:296] (main) Using RMI server codebase: http://127.0.0.1:8083/

In this case, it should be,

2010-09-21 11:32:23,380 INFO [org.jboss.web.WebService:309] (main) Using RMI server codebase: http://127.0.0.1:8083/

Environment

  • JBoss Enterprise Application Platform (EAP)
    • 5.0.1
    • 5.1.0

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In

New to Red Hat?

Learn more about Red Hat subscriptions

Using a Red Hat product through a public cloud?

How to access this content