My Oracle Support Banner

Weblogic Log Filtering Issue With New Line Characters (Doc ID 1324853.1)

Last updated on NOVEMBER 14, 2018

Applies to:

Oracle Weblogic Server - Version: 10.3 and later   [Release: and later ]
Oracle Service Bus - Version: 10.3 to 10.3.1   [Release: AS10gR3 to AS10gR3]
Information in this document applies to any platform.

Symptoms

On Weblogic Server 10.3.0 a log filter was created to remove all lines that match a pattern (in this case "ENS-DDS").

The following content was tested and used as source for the log filter. Please note that content includes new line characters ("\n").

NonCatalogLogger myLog = new NonCatalogLogger("Test WLS only");
myLog.info("ENS-DDS - Test1 does not work: <smids>\n\t<smids1/>\n</smids>");
myLog.info("ENS-DDS - Test2 does not work: foo\nboo");
myLog.info("ENS-DDS - Test3 does work: <smids><smids1/></smids>");
myLog.info("ENS-DDS - Test4 does work: foo boo");
myLog.info("ENS-DDS: After the for-each. This round of processing all done.");


Results in the server log are the following:

####<May 5, 2011 9:43:47 AM CLT> <Info> <Test WLS only> <jazz> <AdminServer> <[ACTIVE] ExecuteThread: '2' for queue: 'weblogic.kernel.Default (self-tuning)'> <> <> <> <1304603027843> <BEA-000000> <ENS-DDS - Test1 does not work: <smids>
<smids1/>
</smids>>
####<May 5, 2011 9:43:47 AM CLT> <Info> <Test WLS only> <jazz> <AdminServer> <[ACTIVE] ExecuteThread: '2' for queue: 'weblogic.kernel.Default (self-tuning)'> <> <> <> <1304603027844> <BEA-000000> <ENS-DDS - Test2 does not work: foo
boo>
####<May 5, 2011 9:43:47 AM CLT> <Info> <Test WLS only> <jazz> <AdminServer> <[ACTIVE] ExecuteThread: '2' for queue: 'weblogic.kernel.Default (self-tuning)'> <> <> <> <1304603027844> <BEA-000000> <ENS-DDS - Test3 does work: <smids><smids1/></smids>>
####<May 5, 2011 9:43:47 AM CLT> <Info> <Test WLS only> <jazz> <AdminServer> <[ACTIVE] ExecuteThread: '2' for queue: 'weblogic.kernel.Default (self-tuning)'> <> <> <> <1304603027844> <BEA-000000> <ENS-DDS - Test4 does work: foo boo>
####<May 5, 2011 9:43:47 AM CLT> <Info> <Test WLS only> <jazz> <AdminServer> <[ACTIVE] ExecuteThread: '2' for queue: 'weblogic.kernel.Default (self-tuning)'> <> <> <> <1304603027844> <BEA-000000> <ENS-DDS: <AfterForEach><Msg>After the for-each. This round of processing all done.</Msg></AfterForEach>>


The expected behavior is that all lines with ENS-DDS should be filtered.

Thus in this case we find that the log filter is not working as expected.

Cause

To view full details, sign in with your My Oracle Support account.

Don't have a My Oracle Support account? Click to get started!


In this Document
  Symptoms
  Cause
  Solution
  References

My Oracle Support provides customers with access to over a million knowledge articles and a vibrant support community of peers and Oracle experts.