Package org.apache.jackrabbit.oak.spi.state

Examples of org.apache.jackrabbit.oak.spi.state.ApplyDiff


                    // so use the backed up state as the basis of the
                    // incremental backup diff
                    before = state.getChildNode("root");
                }
                current.compareAgainstBaseState(
                        before, new ApplyDiff(builder.child("root")));
            }
            builder.setProperty("checkpoint", checkpoint);

            // 4. commit the backup
            journal.setHead(
View Full Code Here


            log.error(errorMsg, e);
            throw new RuntimeException(e);
        }

        NodeState target = store.getRoot();
        target.compareAgainstBaseState(base, new ApplyDiff(builder));
    }
View Full Code Here

        NodeState base = builder.getNodeState();
        NodeStore store = new MemoryNodeStore(base);
        BuiltInNodeTypes.register(new SystemRoot(
                store, new EditorHook(new RegistrationEditorProvider())));
        NodeState target = store.getRoot();
        target.compareAgainstBaseState(base, new ApplyDiff(builder));
    }
View Full Code Here

            log.error(errorMsg, e);
            throw new RuntimeException(e);
        }

        NodeState target = store.getRoot();
        target.compareAgainstBaseState(base, new ApplyDiff(builder));
    }
View Full Code Here

    public static void restore(NodeState source, NodeStore store)
            throws CommitFailedException {
        long s = System.currentTimeMillis();
        NodeState after = store.getRoot();
        NodeBuilder builder = after.builder();
        source.compareAgainstBaseState(after, new ApplyDiff(builder));
        store.merge(builder, EmptyHook.INSTANCE, CommitInfo.EMPTY);
        log.debug("Restore finished in {} ms.", System.currentTimeMillis() - s);
    }
View Full Code Here

            log.error(errorMsg, e);
            throw new RuntimeException(e);
        }

        NodeState target = store.getRoot();
        target.compareAgainstBaseState(base, new ApplyDiff(builder));
    }
View Full Code Here

    public static void restore(NodeState source, NodeStore store)
            throws CommitFailedException {
        long s = System.currentTimeMillis();
        NodeState after = store.getRoot();
        NodeBuilder builder = after.builder();
        source.compareAgainstBaseState(after, new ApplyDiff(builder));
        store.merge(builder, EmptyHook.INSTANCE, null);
        log.debug("Restore finished in {} ms.", System.currentTimeMillis() - s);
    }
View Full Code Here

        NodeStore store = new MemoryNodeStore(base);
        BuiltInNodeTypes.register(new SystemRoot(store, new EditorHook(
                new CompositeEditorProvider(new NamespaceEditorProvider(),
                        new RegistrationEditorProvider()))));
        NodeState target = store.getRoot();
        target.compareAgainstBaseState(base, new ApplyDiff(builder));
    }
View Full Code Here

            } catch (RepositoryException e) {
                log.error("Failed to register built-in privileges", e);
                throw new RuntimeException(e);
            }
            NodeState target = store.getRoot();
            target.compareAgainstBaseState(base, new ApplyDiff(builder));
        }
    }
View Full Code Here

            log.error(errorMsg, e);
            throw new RuntimeException(e);
        }

        NodeState target = store.getRoot();
        target.compareAgainstBaseState(base, new ApplyDiff(builder));
    }
View Full Code Here

TOP

Related Classes of org.apache.jackrabbit.oak.spi.state.ApplyDiff

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.