Skip to content

Commit

Permalink
Allow ALL value for loggers in Admin Console.
Browse files Browse the repository at this point in the history
Before this, Admin Console was showing OFF level instead of ALL level, and saved the OFF level even 
if a user didn't change this intentionally.
ALL is used for GlassFishLogHandler by default, and, according to Javadoc,
it's also a valid value for logger levels, meaning that all messages are logged.

Keep the OFF default level for new loggers as before.
Signed-off-by:Ondro Mihalyi <mihalyi@omnifish.ee>
  • Loading branch information
OndroMih committed Apr 27, 2023
1 parent e43aa3c commit ad9f4e1
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,8 @@
loggerLevels="#{requestScope.loggerLevels.data.extraProperties.logLevels}"
loggerList="#{requestScope.tableList}");

setPageSessionAttribute(key="levelList" value={"OFF" "FINEST" "FINER" "FINE" "CONFIG" "INFO" "WARNING" "SEVERE" "ALERT" "EMERGENCY"})
setPageSessionAttribute(key="levelList" value={"ALL" "FINEST" "FINER" "FINE" "CONFIG" "INFO" "WARNING" "SEVERE" "ALERT" "EMERGENCY" "OFF"});
setPageSessionAttribute(key="defaultNewLevel" value="OFF");
gf.isConfigName(configName="#{pageSession.configName}" );
/>
</event>
Expand Down Expand Up @@ -75,7 +76,7 @@
<sun:button id="addSharedTableButton" disabled="#{false}" text="$resource{i18nc.log.addLogger}" >
<!command
getUIComponent(clientId="$pageSession{tableRowGroupId}", component=>$attribute{tableRowGroup});
addRowToTable(TableRowGroup="$attribute{tableRowGroup}", NameList={"loggerName", "level"});
addRowToTable(TableRowGroup="$attribute{tableRowGroup}", NameList={"loggerName", "level"}, DefaultValueList={"","$pageSession{defaultNewLevel}"});
/>
</sun:button>

Expand Down

0 comments on commit ad9f4e1

Please sign in to comment.