You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@sling.apache.org by "Christanto (JIRA)" <ji...@apache.org> on 2015/07/07 15:41:04 UTC

[jira] [Created] (SLING-4860) Vanity Path cannot be used for MergedResource (or virtual resource)

Christanto created SLING-4860:
---------------------------------

             Summary: Vanity Path cannot be used for MergedResource (or virtual resource)
                 Key: SLING-4860
                 URL: https://issues.apache.org/jira/browse/SLING-4860
             Project: Sling
          Issue Type: Improvement
          Components: Engine
            Reporter: Christanto


Currently the vanity path config is specified at the target node:
{code}
+ /libs/mypage
  - jcr:mixinTypes = "sling:VanityPath"
  - sling:vanityOrder = 100
  - sling:vanityPath = "/index"
{code}

The page can be then accessed at {{/libs/mypage.html}} or {{/index.html}}.

Since Resource Merger, the preferable path to access the content is actually {{/mnt/overlay/mypage.html}}. However since the vanity path config can only specified at the target node, we cannot do that.

My suggestion is to expose one more optional property to {{sling:VanityPath}} to specify the target so that the config can be specified anywhere.

{code}
+ /libs/mypage
  - jcr:mixinTypes = "sling:VanityPath"
  - sling:vanityOrder = 100
  - sling:vanityPath = "/index"
  - sling:target = "/mnt/overlay/mypage"
{code}



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