Class VersionHook

  • All Implemented Interfaces:
    org.apache.jackrabbit.oak.spi.commit.CommitHook

    public class VersionHook
    extends java.lang.Object
    implements org.apache.jackrabbit.oak.spi.commit.CommitHook
    This class gathers together editors related to handling version storage:
    1. VersionEditorProvider
      • VersionEditor - creates version history, handles checking-in, checking-out and restoring, prevents a checked-in node from being modified,
      • VersionStorageEditor - validates changes on the version storage,
    2. VersionableCollector - collects all existing versionable UUIDs, so assigned histories won't be removed in the next step,
    3. OrphanedVersionCleaner - removes all histories that are empty and have no longer a parent versionable node.
    • Constructor Summary

      Constructors 
      Constructor Description
      VersionHook()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      @NotNull org.apache.jackrabbit.oak.spi.state.NodeState processCommit​(org.apache.jackrabbit.oak.spi.state.NodeState before, org.apache.jackrabbit.oak.spi.state.NodeState after, org.apache.jackrabbit.oak.spi.commit.CommitInfo info)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • VersionHook

        public VersionHook()
    • Method Detail

      • processCommit

        @NotNull
        public @NotNull org.apache.jackrabbit.oak.spi.state.NodeState processCommit​(org.apache.jackrabbit.oak.spi.state.NodeState before,
                                                                                    org.apache.jackrabbit.oak.spi.state.NodeState after,
                                                                                    org.apache.jackrabbit.oak.spi.commit.CommitInfo info)
                                                                             throws org.apache.jackrabbit.oak.api.CommitFailedException
        Specified by:
        processCommit in interface org.apache.jackrabbit.oak.spi.commit.CommitHook
        Throws:
        org.apache.jackrabbit.oak.api.CommitFailedException