Examples of ChangeDispatcher


Examples of org.apache.jackrabbit.oak.spi.commit.ChangeDispatcher

    private static final int COMMITS_PER_WRITER = 100;

    @Test
    public void concurrentCommits() throws Exception {
        final MongoNodeStore store = new MongoMK.Builder().getNodeStore();
        ChangeDispatcher dispatcher = new ChangeDispatcher(store.getRoot());
        AtomicBoolean running = new AtomicBoolean(true);
        final CommitQueue queue = new CommitQueue(store, dispatcher);
        final List<Exception> exceptions = Collections.synchronizedList(new ArrayList<Exception>());

        Closeable observer = dispatcher.addObserver(new Observer() {
            private Revision before = new Revision(0, 0, store.getClusterId());

            @Override
            public void contentChanged(@Nonnull NodeState root, @Nullable CommitInfo info) {
                MongoNodeState after = (MongoNodeState) root;
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.