Uploaded image for project: 'Application Server 3  4  5 and 6'
  1. Application Server 3 4 5 and 6
  2. JBAS-4413

Incorrect behaviour in TCLFilter

    XMLWordPrintable

Details

    • Bug
    • Resolution: Obsolete
    • Major
    • No Release
    • JBossAS-4.0.5.GA
    • Logging
    • None
    • Low

    Description

      Just one TCLFilter can be added to an appender, decide method return either ACCEPT or DENY.
      Should return NEUTRAL is some case.

      public int decide(LoggingEvent event)
      {
      int ok = Filter.DENY;
      if( acceptOnMatch == true )
      {
      ok = Filter.DENY;
      if( isMatchingTCL() ){
      ok = Filter.ACCEPT;
      }
      }
      else
      {
      ok = Filter.ACCEPT; // CHANGING THIS ROW TO ok = Filter.NEUTRAL; should do that you check the other filters to.
      if( isMatchingTCL() )
      ok = Filter.DENY;
      }
      return ok;
      }

      Log4j.xml:

      <appender name="CONSOLE" class="org.apache.log4j.ConsoleAppender">
      <layout class="org.apache.log4j.PatternLayout">
      <param name="ConversionPattern" value="%d %-5p [%t] %c - %m%n"/>
      </layout>
      <filter class="org.jboss.logging.filter.TCLFilter">
      <param name="AcceptOnMatch" value="false"/>
      <param name="DeployURL" value="jboss-common-client.jarpoyan"/>
      </filter>
      <filter class="org.jboss.logging.filter.TCLFilter">
      <param name="AcceptOnMatch" value="false"/>
      <param name="DeployURL" value="dnsns.jarpoyan"/>
      </filter>
      </appender>

      Attachments

        Activity

          People

            starksm64 Scott Stark (Inactive)
            poyge394 Poyan Gerami (Inactive)
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Time Tracking

                Estimated:
                Original Estimate - 30 minutes
                30m
                Remaining:
                Remaining Estimate - 30 minutes
                30m
                Logged:
                Time Spent - Not Specified
                Not Specified