[jira] [Commented] (SLING-6114) Support nested configurations in configurated locations
[ https://issues.apache.org/jira/browse/SLING-6114?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=1405#comment-1405 ] ASF GitHub Bot commented on SLING-6114: --- Github user stefanseifert closed the pull request at: https://github.com/apache/sling/pull/179 > Support nested configurations in configurated locations > --- > > Key: SLING-6114 > URL: https://issues.apache.org/jira/browse/SLING-6114 > Project: Sling > Issue Type: Improvement > Components: Extensions >Reporter: Carsten Ziegeler >Assignee: Stefan Seifert > Labels: contextaware-config > Fix For: Context-Aware Configuration 1.0.0 > > > Let's assume you have a content like this: > /content/level1/level2[@sling-config-ref='/conf/project/sub'] > and configurations > /conf/project/something > /conf/project/sub/something-else > the default path strategy should directly go up the hierarchy in the > configured location (/conf in this case), so /conf/project/sub is tried > first, then /conf/project and then the other configured paths. > The only question is if you have > /libs/conf/project/sub > is this handled before /conf/project or after? -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (SLING-6114) Support nested configurations in configurated locations
[ https://issues.apache.org/jira/browse/SLING-6114?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=1379#comment-1379 ] Carsten Ziegeler commented on SLING-6114: - [~sseif...@pro-vision.de] Yed I think that makes sense, just having /conf and the other paths are ordered fallbacks > Support nested configurations in configurated locations > --- > > Key: SLING-6114 > URL: https://issues.apache.org/jira/browse/SLING-6114 > Project: Sling > Issue Type: Improvement > Components: Extensions >Reporter: Carsten Ziegeler >Assignee: Stefan Seifert > Labels: contextaware-config > Fix For: Context-Aware Configuration 1.0.0 > > > Let's assume you have a content like this: > /content/level1/level2[@sling-config-ref='/conf/project/sub'] > and configurations > /conf/project/something > /conf/project/sub/something-else > the default path strategy should directly go up the hierarchy in the > configured location (/conf in this case), so /conf/project/sub is tried > first, then /conf/project and then the other configured paths. > The only question is if you have > /libs/conf/project/sub > is this handled before /conf/project or after? -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (SLING-6114) Support nested configurations in configurated locations
[ https://issues.apache.org/jira/browse/SLING-6114?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=1362#comment-1362 ] Stefan Seifert commented on SLING-6114: --- proposal: https://github.com/apache/sling/pull/179 some remarks: * implementation works as described above including the special usecase * i saw that the your assumption from the ticket description which i answered in [this comment|https://issues.apache.org/jira/browse/SLING-6114?focusedCommentId=1129#comment-1129] was somewhat implemented already at least how the osgi config was defined previously: ** it defined allowed path /conf, /apps/conf, /libs/conf - with any path hierarchy ** so it would be possible to store deep hierarchy of config below /apps/conf and /libs/conf for this whitelist, although the remaining implementation did not support this ** and it would be possible for a content resource to reference a config resource below or equals /apps/conf and /libs/conf and /conf/global directly, which should not be the case in my opinion - these are only fallback path, and referencing a global config directly makes no sense when using context-aware config without any context * so i changed the implementation to allow only one single (configurable) path where configuration are stored in (default: /conf), and allowing only references to resources below this path (i will update the PR to disallow references to /conf/global) as well. [~cziegeler] what is your opinion on this whitelist/reference aspect? > Support nested configurations in configurated locations > --- > > Key: SLING-6114 > URL: https://issues.apache.org/jira/browse/SLING-6114 > Project: Sling > Issue Type: Improvement > Components: Extensions >Reporter: Carsten Ziegeler >Assignee: Stefan Seifert > Labels: contextaware-config > Fix For: Context-Aware Configuration 1.0.0 > > > Let's assume you have a content like this: > /content/level1/level2[@sling-config-ref='/conf/project/sub'] > and configurations > /conf/project/something > /conf/project/sub/something-else > the default path strategy should directly go up the hierarchy in the > configured location (/conf in this case), so /conf/project/sub is tried > first, then /conf/project and then the other configured paths. > The only question is if you have > /libs/conf/project/sub > is this handled before /conf/project or after? -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (SLING-6114) Support nested configurations in configurated locations
[ https://issues.apache.org/jira/browse/SLING-6114?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=1349#comment-1349 ] ASF GitHub Bot commented on SLING-6114: --- GitHub user stefanseifert opened a pull request: https://github.com/apache/sling/pull/179 SLING-6114 Support nested configurations in configurated locations You can merge this pull request into a Git repository by running: $ git pull https://github.com/stefanseifert/sling feature/SLING-6114-nested-conf-configs Alternatively you can review and apply these changes as the patch at: https://github.com/apache/sling/pull/179.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #179 commit ecb73376117af30bf99c1c2aff51e00737d8f56b Author: sseifertDate: 2016-10-07T15:00:40Z SLING-6114 Support nested configurations in configured locations commit b43fd8daebf5a801007a1df0eec69ceacb4019a9 Author: sseifert Date: 2016-10-07T15:12:21Z SLING-6114 Allow only one single (configurable) path to store configurations in, and to reference to > Support nested configurations in configurated locations > --- > > Key: SLING-6114 > URL: https://issues.apache.org/jira/browse/SLING-6114 > Project: Sling > Issue Type: Improvement > Components: Extensions >Reporter: Carsten Ziegeler >Assignee: Stefan Seifert > Labels: contextaware-config > Fix For: Context-Aware Configuration 1.0.0 > > > Let's assume you have a content like this: > /content/level1/level2[@sling-config-ref='/conf/project/sub'] > and configurations > /conf/project/something > /conf/project/sub/something-else > the default path strategy should directly go up the hierarchy in the > configured location (/conf in this case), so /conf/project/sub is tried > first, then /conf/project and then the other configured paths. > The only question is if you have > /libs/conf/project/sub > is this handled before /conf/project or after? -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (SLING-6114) Support nested configurations in configurated locations
[ https://issues.apache.org/jira/browse/SLING-6114?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=1182#comment-1182 ] Carsten Ziegeler commented on SLING-6114: - Yes I think case #1 is what you would expect > Support nested configurations in configurated locations > --- > > Key: SLING-6114 > URL: https://issues.apache.org/jira/browse/SLING-6114 > Project: Sling > Issue Type: Improvement > Components: Extensions >Reporter: Carsten Ziegeler >Assignee: Stefan Seifert > Labels: contextaware-config > Fix For: Context-Aware Configuration 1.0.0 > > > Let's assume you have a content like this: > /content/level1/level2[@sling-config-ref='/conf/project/sub'] > and configurations > /conf/project/something > /conf/project/sub/something-else > the default path strategy should directly go up the hierarchy in the > configured location (/conf in this case), so /conf/project/sub is tried > first, then /conf/project and then the other configured paths. > The only question is if you have > /libs/conf/project/sub > is this handled before /conf/project or after? -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (SLING-6114) Support nested configurations in configurated locations
[ https://issues.apache.org/jira/browse/SLING-6114?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=1175#comment-1175 ] Stefan Seifert commented on SLING-6114: --- there is one special case - consider this scenario {noformat} /content/level1[@config-ref='/conf/a1/a2'] /content/level1/level2[@config-ref='/conf/b1/b2'] {noformat} what is the expected lookup order for {{/content/level1/level2}}? # {noformat} /conf/b1/b2 /conf/b1 /conf/a1/a2 /conf/a1 /conf/global /apps/conf /libs/conf {noformat} # {noformat} /conf/b1/b2 /conf/a1/a2 /conf/b1 /conf/a1 /conf/global /apps/conf /libs/conf {noformat} or asking other way around: which inheritance hierarchy has higher priority? parent resources of the conf resources, or conf resources referenced by parent resources of the content resource? for me case #1 feels more sensible. > Support nested configurations in configurated locations > --- > > Key: SLING-6114 > URL: https://issues.apache.org/jira/browse/SLING-6114 > Project: Sling > Issue Type: Improvement > Components: Extensions >Reporter: Carsten Ziegeler >Assignee: Stefan Seifert > Labels: contextaware-config > Fix For: Context-Aware Configuration 1.0.0 > > > Let's assume you have a content like this: > /content/level1/level2[@sling-config-ref='/conf/project/sub'] > and configurations > /conf/project/something > /conf/project/sub/something-else > the default path strategy should directly go up the hierarchy in the > configured location (/conf in this case), so /conf/project/sub is tried > first, then /conf/project and then the other configured paths. > The only question is if you have > /libs/conf/project/sub > is this handled before /conf/project or after? -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (SLING-6114) Support nested configurations in configurated locations
[ https://issues.apache.org/jira/browse/SLING-6114?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=1156#comment-1156 ] Carsten Ziegeler commented on SLING-6114: - Ups, you're of course right - just forget my question :) > Support nested configurations in configurated locations > --- > > Key: SLING-6114 > URL: https://issues.apache.org/jira/browse/SLING-6114 > Project: Sling > Issue Type: Improvement > Components: Extensions >Reporter: Carsten Ziegeler >Assignee: Stefan Seifert > Labels: contextaware-config > Fix For: Context-Aware Configuration 1.0.0 > > > Let's assume you have a content like this: > /content/level1/level2[@sling-config-ref='/conf/project/sub'] > and configurations > /conf/project/something > /conf/project/sub/something-else > the default path strategy should directly go up the hierarchy in the > configured location (/conf in this case), so /conf/project/sub is tried > first, then /conf/project and then the other configured paths. > The only question is if you have > /libs/conf/project/sub > is this handled before /conf/project or after? -- This message was sent by Atlassian JIRA (v6.3.4#6332)
[jira] [Commented] (SLING-6114) Support nested configurations in configurated locations
[ https://issues.apache.org/jira/browse/SLING-6114?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=1129#comment-1129 ] Stefan Seifert commented on SLING-6114: --- {quote} The only question is if you have /libs/conf/project/sub is this handled before /conf/project or after? {quote} we currently do not have any support for deep structuring levels in /apps/conf or /libs/conf, both are just a "single level" with default resources for the given configuration names. thus neither {{/libs/conf/project/sub}} nor {{/libs/conf/project}} should be looked up, only {{/libs/conf}}. or do you see a need for supporting all this hierarchy in /apps and /libs as well? > Support nested configurations in configurated locations > --- > > Key: SLING-6114 > URL: https://issues.apache.org/jira/browse/SLING-6114 > Project: Sling > Issue Type: Improvement > Components: Extensions >Reporter: Carsten Ziegeler >Assignee: Stefan Seifert > Labels: contextaware-config > Fix For: Context-Aware Configuration 1.0.0 > > > Let's assume you have a content like this: > /content/level1/level2[@sling-config-ref='/conf/project/sub'] > and configurations > /conf/project/something > /conf/project/sub/something-else > the default path strategy should directly go up the hierarchy in the > configured location (/conf in this case), so /conf/project/sub is tried > first, then /conf/project and then the other configured paths. > The only question is if you have > /libs/conf/project/sub > is this handled before /conf/project or after? -- This message was sent by Atlassian JIRA (v6.3.4#6332)