-
Notifications
You must be signed in to change notification settings - Fork 60
LUTECE-2196 : Allow to reload the log4j configuration at runtime #140
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: develop
Are you sure you want to change the base?
Conversation
@@ -68,6 +68,7 @@ manage_caches.actionDisable=Turn off | |||
manage_caches.actionViewKeys=View config and keys | |||
manage_caches.buttonFlush=Flush all | |||
manage_caches.buttonViewKeys=View config and keys | |||
manage_caches.titleReloadLogsConfiguration=Log configuration loading |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Wouldn't that be "reloading" ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I chose the same expression as the other "reloading" button which says "Properties Loading". I don't have a strong opinion
@@ -70,6 +71,10 @@ | |||
private static final String TEMPLATE_CACHE_INFOS = "admin/system/cache_infos.html"; | |||
private static final String PARAMETER_ID_CACHE = "id_cache"; | |||
|
|||
// Conf | |||
private static final String PATH_CONF = "/WEB-INF/conf/"; | |||
private static final String FILE_PROPERTIES_CONFIG = "config.properties"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe you shoud not redefine these constants here, but share them with the normal intialisation process. Otherwise, there is a risk these become desynchronized
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's already defined in several places as private constants... Not sure if it's useful to declare them as public constants. Maybe in fr.paris.lutece.portal.web.constants.Parameters ? but it looks like this class is for parameters of http requests.
|
||
return JSP_MANAGE_CACHES; | ||
} | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You should be able to add tests that
- ensure the CSRF protection is enforced
- verify that the log configuration is indeed changed
@@ -7,6 +7,10 @@ | |||
<@button type='submit' buttonIcon='refresh' title='#i18n{portal.system.manage_caches.titleReloadProperties}' id='reload' size='' showTitleXs=false showTitleSm=false /> | |||
<@aButton href='jsp/admin/system/CacheInfos.jsp' buttonIcon='key' title='#i18n{portal.system.manage_caches.buttonViewKeys}' size='' showTitleXs=false showTitleSm=false /> | |||
</@tform> | |||
<@tform method='post' action='jsp/admin/system/DoReloadLogsConfiguration.jsp' class='pull-right spaced'> | |||
<input type="hidden" name="token" value="${token}"> | |||
<@button type='submit' buttonIcon='refresh' title='#i18n{portal.system.manage_caches.titleReloadLogsConfiguration}' id='reloadLogsConf' size='' showTitleXs=false showTitleSm=false /> |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
So the button shows no text on small screens ? Since there are no tooltips on smartphone, the purpose of this button might not be obvious
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
If we go with having this button on this page, then maybe we can use a single letter to disambiguate ? L and P. Or Logs and Props ? Or Logs and Properties ?
If we put this functionality in another page maybe the "reload" glyph is enough
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why not just display the title at all sizes ?
Thanks for the review, I'll fix the problems you found |
135e4f9
to
e399c1d
Compare
We should discuss where we want this feature