Uploaded image for project: 'Sling'
  1. Sling
  2. SLING-1778

Symlinks / Superimposing Resources

    XMLWordPrintableJSON

Details

    Description

      I have implemented a ResourceProvider, which allows to create symlink nodes in the JCR repository. A symlink node has a sling:symlinkTarget property, which should contain a valid JCR path. JCR content from the sling:symlinkTarget path is then exposed below the symlink node.

      There is a mixin node type, sling:Symlink with a mandatory property sling:symlinkTarget and an optional property sling:overlayable. Additionally, there is a convenience node type, sling:SymlinkResource, which extends from sling:symlinkTarget and nt:unstructured.

      ResourceProvider instances are registered for existing symlinks when the bundle is started. Modifications are taken care of via JCR observation.

      To get started:

      • apply the attached patch to a trunk checkout
      • build and install the bundle
      • create a symlink node, pointing to some existing content
      • access the symlink node e.g. via a browser

      Attachments

        1. 130704_symlinks-0.0.4.patch
          49 kB
          Stefan Seifert
        2. symlinks.patch
          32 kB
          Julian Sedding

        Issue Links

          Activity

            People

              Unassigned Unassigned
              jsedding Julian Sedding
              Votes:
              0 Vote for this issue
              Watchers:
              7 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: