You are viewing a plain text version of this content. The canonical link for it is here.
Posted to oak-issues@jackrabbit.apache.org by "angela (JIRA)" <ji...@apache.org> on 2017/01/10 17:33:58 UTC

[jira] [Commented] (OAK-5249) DefaultAuthorizableActionProvider should use @Modified to react to config changes

    [ https://issues.apache.org/jira/browse/OAK-5249?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15815600#comment-15815600 ] 

angela commented on OAK-5249:
-----------------------------

[~tripod], would you mind also providing a test-case illustrating the improvement? suggested location for this kind of tests would be {{oak-pojosr}} module, where we already have some tests for the OSGi-setup of the {{SecurityProvider}}.

> DefaultAuthorizableActionProvider should use @Modified to react to config changes
> ---------------------------------------------------------------------------------
>
>                 Key: OAK-5249
>                 URL: https://issues.apache.org/jira/browse/OAK-5249
>             Project: Jackrabbit Oak
>          Issue Type: Improvement
>          Components: core
>    Affects Versions: 1.5.14
>            Reporter: Tobias Bocanegra
>
> The DefaultAuthorizableActionProvider [0] doesn't handle the @Modified component description, causing entire OAK to restart when the config changes. 
> suggested change:
> {code}
> 	@Activate
> 	private void activate(Map<String, Object> properties) {
> 		this.modified(properties);
> 	}	
> 	@Modified
> 	private void modified(Map<String, Object> properties) {
> 		config = ConfigurationParameters.of(properties);
> 		enabledActions = config.getConfigValue(ENABLED_ACTIONS, DEFAULT_ACTIONS);
> 	}		
> {code}
> [0] https://github.com/apache/jackrabbit-oak/blob/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/spi/security/user/action/DefaultAuthorizableActionProvider.java



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)