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

Sling Pipes to write metadata on modified resources

    XMLWordPrintableJSON

Details

    • Improvement
    • Status: Closed
    • Minor
    • Resolution: Fixed
    • None
    • Pipes 4.3.0
    • pipes
    • None

    Description

      Background

      Sling Pipes modify content without leaving a trace in the repository. Developers should have the ability to mark resources modified by the Sling Pipe. While modifying the resource, the 'Write' Sling pipe could also set metadata info indicating the time of modification and the author of the change.
      Example: pipe 'enable-foo' sets the property foo=true on nodeA.
      without metadata:
      nodeA
          foo=true

      with metadata:
      nodeA
          foo = true
          jcr:lastModified = 2021-08-09T11:06:56.753+02:00
          jcr:lastModifiedBy = sling-pipe-enable-foo

       

      Suggestion

      To add a 'metadata' flag to content modification pipes. When set to true, the pipe will set 2 properties on each modified resource:

      •  'jcr:lastModified' - current server's DateTime.
      • 'jcr:lastModifiedBy' - 'sling-pipe-${pipe_name}'

      By default, the metadata flag is set to false and will do nothing.

      Q1. should we make 'jcr:lastModifiedBy' - 'sling-pipe-${pipe_name} on behalf of ${user}'?
      Q2. what other pipes to adapt

      Attachments

        Activity

          People

            npeltier Nicolas Peltier
            lukianet Mariia Lukianets
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: