Class SourceUpdateServlet

  • All Implemented Interfaces:
    RestrictedService, Serializable, javax.servlet.Servlet, javax.servlet.ServletConfig

    public class SourceUpdateServlet
    extends org.apache.sling.api.servlets.SlingAllMethodsServlet
    implements RestrictedService
    Modifies JCR content according to a given XML or ZIP of XMLs while preserving / updating metadata like versioning information and metadata. This is a kind of opposite operation as the SourceServlet: the nodes like jcr:lastModified, which are removed there, will just be updated here - if they occur in our input, they'll be ignored. This is somewhat in beta stage - use at your own risk.

    TODO: perhaps keep special nodes like cpp:MetaData (used for statistics) unchanged

    See Also:
    Serialized Form
    • Constructor Detail

      • SourceUpdateServlet

        public SourceUpdateServlet()
    • Method Detail

      • doPost

        protected void doPost​(@NotNull
                              @NotNull org.apache.sling.api.SlingHttpServletRequest request,
                              @NotNull
                              @NotNull org.apache.sling.api.SlingHttpServletResponse response)
                       throws IOException
        Overrides:
        doPost in class org.apache.sling.api.servlets.SlingAllMethodsServlet
        Throws:
        IOException