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

Carsten Ziegeler commented on SLING-9961:
-----------------------------------------

Agreed, I think we should simply drop that code

> DefaultAclManager: redundant creation of intermediate path
> ----------------------------------------------------------
>
>                 Key: SLING-9961
>                 URL: https://issues.apache.org/jira/browse/SLING-9961
>             Project: Sling
>          Issue Type: Bug
>          Components: Content-Package to Feature Model Converter
>            Reporter: Angela Schreiber
>            Priority: Minor
>             Fix For: Content-Package to Feature Model Converter 1.0.24
>
>
> {code}
> // TODO does it harm?!?
> addSystemUserPath(formatter, systemUser.getPath());
> {code}
> where the method looks as follows:
> {code}
> private final void addSystemUserPath(Formatter formatter, RepoPath path) {
>         if (preProvidedSystemPaths.add(path)) {
>             formatter.format("create path (rep:AuthorizableFolder) %s%n", 
> path);
>         }
>     }
> {code}
> i would strong recommend to drop that. the 
> content-package-feature-model-converter already has quite some hardcoded 
> stuff.... how the intermediate path argument passed to 
> {{UserManager.createSystemUser(String id, String intermediatePath)}} is used 
> and what node types are used to create the hierarchy should be considered an 
> implementation detail and it doesn't make sense IMHO to eagerly create the 
> tree structure in a feature like this. in fact i would consider this a bug 
> that may sooner or later cause the converter to fail during repo-init 
> execution.
> btw: the comment already implies that the author was not sure of the 
> usefulness.... why not verifying and fixing the code or dropping the TODO 
> before releasing the module?



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

Reply via email to