[GLASSFISH-19494] list-log-attributes does not include "multiLineMode" nor "ODLLogFormatter.excludeFields" Created: 04/Jan/13  Updated: 19/Feb/13  Resolved: 19/Feb/13

Status: Resolved
Project: glassfish
Component/s: logging
Affects Version/s: 4.0_b70
Fix Version/s: 4.0_b71

Type: Bug Priority: Major
Reporter: Anissa Lam Assignee: sandeep.shrivastava
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Dependency
blocks GLASSFISH-19618 ODLLogFormatter.excludeFields should ... Resolved
blocks GLASSFISH-19491 Add all the new attributes relating t... Resolved

 Description   

2 issues relating ot the logging attributes.

#1. The logging attribute
"com.sun.enterprise.server.logging.GFFileHandler.multiLineMode" is not included in the out-of-box loggings.properties file. As a result,
%asadmin list-log-attributes
does not include this attribute and value.

Need to add this attribute to the loggings.properties file so that list-log-attributes will include it.
Basically, I need the list-log-attributes to return this attribute and value out-of-box.

============
#2. According to the logging requirement doc, one can set the excludes fields as followed. But running the set-log-attributes command returns error.

%asadmin set-log-attributes com.sun.enterprise.server.logging.ODLLogFormatter.excludeFields=userid
remote failure: Invalid logging attribute name found com.sun.enterprise.server.logging.ODLLogFormatter.excludeFields.
Command set-log-attributes failed.


 Comments   
Comment by Anissa Lam [ 05/Jan/13 ]

I have worked around #1 in the console, so the multi line mode is already available in the logging attribute screen.
I still think that should be fixed.

After #2 is fixed, i will add the UI for that.

Comment by Anissa Lam [ 21/Jan/13 ]

The console screen has added the 'Load Default' button.
Console allows editing of the "com.sun.enterprise.server.logging.GFFileHandler.multiLineMode" attribute with the work around.
However, since this is not included in the defaultLoggingProperties list either, this is treated as no default value when user press the Load Default Button.

Comment by sandeep.shrivastava [ 01/Feb/13 ]

Committed revision 58987. Added the properties in the template config file.

Comment by Anissa Lam [ 18/Feb/13 ]

I am reopening the issue.
I just updated my workspace to the latest version, there is still the following issues.

According to the logging requirement
http://aseng-wiki.us.oracle.com/asengwiki/display/GlassFish/Logging+Requirements+One+Pager#LoggingRequirementsOnePager-4.1.6LogFormat

The attribute name should be "ODLLogFormatter.excludeFields'. I will expect list-log-attributes to return this.
But list-log-attributes still does not include that.
Here is the result:

{{
~/Awork/BG/glassfish4/glassfish/bin 4) asadmin list-log-attributes
com.sun.enterprise.server.logging.GFFileHandler.excludeFields <>
com.sun.enterprise.server.logging.GFFileHandler.file <$

{com.sun.aas.instanceRoot}

/logs/server.log>
com.sun.enterprise.server.logging.GFFileHandler.flushFrequency <1>
com.sun.enterprise.server.logging.GFFileHandler.formatter <com.sun.enterprise.server.logging.UniformLogFormatter>
com.sun.enterprise.server.logging.GFFileHandler.logtoConsole <false>
com.sun.enterprise.server.logging.GFFileHandler.maxHistoryFiles <0>
com.sun.enterprise.server.logging.GFFileHandler.multiLineMode <false>
com.sun.enterprise.server.logging.GFFileHandler.retainErrorsStasticsForHours <0>
com.sun.enterprise.server.logging.GFFileHandler.rotationLimitInBytes <2000000>
com.sun.enterprise.server.logging.GFFileHandler.rotationOnDateChange <false>
com.sun.enterprise.server.logging.GFFileHandler.rotationTimelimitInMinutes <0>
com.sun.enterprise.server.logging.SyslogHandler.useSystemLogging <false>
handlerServices <com.sun.enterprise.server.logging.GFFileHandler>
handlers <java.util.logging.ConsoleHandler>
java.util.logging.ConsoleHandler.formatter <com.sun.enterprise.server.logging.UniformLogFormatter>
java.util.logging.FileHandler.count <1>
java.util.logging.FileHandler.formatter <java.util.logging.XMLFormatter>
java.util.logging.FileHandler.limit <50000>
java.util.logging.FileHandler.pattern <%h/java%u.log>
log4j.logger.org.hibernate.validator.util.Version <warn>
Command list-log-attributes executed successfully.
}}

so, ODLLogFormatter.excludeFields is still missing.

Also, there is still no way to set that attribute:
{{
~/Awork/BG/glassfish4/glassfish/bin 5) asadmin set-log-attributes com.sun.enterprise.server.logging.ODLLogFormatter.excludeFields=userid
remote failure: Invalid logging attribute name found com.sun.enterprise.server.logging.ODLLogFormatter.excludeFields.
Command set-log-attributes failed.

}}

Comment by Anissa Lam [ 19/Feb/13 ]

Sandeep mentioned that the attribute should be com.sun.enterprise.server.logging.GFFileHandler.excludeFields.
Console will be using this attribute name. He can close this bug after updating the one page to correctly reflect the change.

Comment by sandeep.shrivastava [ 19/Feb/13 ]

The one-pager is now updated to reflect the correct attribute name.

Generated at Fri May 22 12:01:55 UTC 2015 using JIRA 6.2.3#6260-sha1:63ef1d6dac3f4f4d7db4c1effd405ba38ccdc558.