Package com.lmax.disruptor.support

Examples of com.lmax.disruptor.support.StubEntry.copy()


        assertEquals(-1L, ringBuffer.cursor());

        StubEntry expectedEntry = new StubEntry(2701);

        StubEntry oldEntry = ringBuffer.nextEntry();
        oldEntry.copy(expectedEntry);
        ringBuffer.commit(oldEntry);

        long sequence = consumerBarrier.waitFor(0);
        assertEquals(0, sequence);
View Full Code Here


        assertEquals(-1L, ringBuffer.cursor());

        StubEntry expectedEntry = new StubEntry(2701);

        StubEntry oldEntry = ringBuffer.nextEntry();
        oldEntry.copy(expectedEntry);
        ringBuffer.commit(oldEntry);

        long sequence = consumerBarrier.waitFor(0, 5, TimeUnit.MILLISECONDS);
        assertEquals(0, sequence);
View Full Code Here

        Future<List<StubEntry>> messages = getMessages(0, 0);

        StubEntry expectedEntry = new StubEntry(2701);

        StubEntry oldEntry = ringBuffer.nextEntry();
        oldEntry.copy(expectedEntry);
        ringBuffer.commit(oldEntry);

        assertEquals(expectedEntry, messages.get().get(0));
    }
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.