@Override protected DeltaStore newDeltaStore() throws IOException { return new MemoryDeltaStore(); } }
@Override public DeltasAccess open(WaveletName waveletName) { Map<WaveletId, MemoryDeltaCollection> waveData = getOrCreateWaveData(waveletName.waveId); MemoryDeltaCollection collection = waveData.get(waveletName.waveletId); if (collection == null) { collection = new MemoryDeltaCollection(waveletName); waveData.put(waveletName.waveletId, collection); } return collection; }
@Override protected DeltaStore newDeltaStore() throws IOException { return new MemoryDeltaStore(); } }
@Override public void setUp() throws Exception { store = new MemoryDeltaStore(); super.setUp(); }
@Override public void setUp() throws Exception { store = new MemoryDeltaStore(); super.setUp(); }
MockitoAnnotations.initMocks(this); final DeltaStore deltaStore = new MemoryDeltaStore(); final Executor persistExecutor = MoreExecutors.sameThreadExecutor(); final Executor storageContinuationExecutor = MoreExecutors.sameThreadExecutor();
@Override public void setUp() throws Exception { super.setUp(); WaveletNotificationSubscriber notifiee = mock(WaveletNotificationSubscriber.class); DeltaStore deltaStore = new MemoryDeltaStore(); AccessController localAccessController = mock(AccessController.class); AccessController remoteAccessController = mock(AccessController.class); WaveletState localWaveletState = DeltaStoreBasedWaveletState.create(deltaStore.open(localWaveletName), PERSIST_EXECUTOR); localWavelet = new LocalWaveletContainerImpl(localWaveletName, notifiee, Futures.immediateFuture(localWaveletState), localDomain, STORAGE_CONTINUATION_EXECUTOR, localAccessController); localWavelet.awaitLoad(); WaveletState remoteWaveletState = DeltaStoreBasedWaveletState.create(deltaStore.open(remoteWaveletName), PERSIST_EXECUTOR); remoteWavelet = new RemoteWaveletContainerImpl(remoteWaveletName, notifiee, Futures.immediateFuture(remoteWaveletState), STORAGE_CONTINUATION_EXECUTOR, remoteAccessController); remoteWavelet.awaitLoad(); }
MockitoAnnotations.initMocks(this); final DeltaStore deltaStore = new MemoryDeltaStore(); final Executor persistExecutor = MoreExecutors.sameThreadExecutor(); final Executor storageContinuationExecutor = MoreExecutors.sameThreadExecutor();
@Override public void setUp() throws Exception { super.setUp(); WaveletNotificationSubscriber notifiee = mock(WaveletNotificationSubscriber.class); DeltaStore deltaStore = new MemoryDeltaStore(); WaveletState localWaveletState = DeltaStoreBasedWaveletState.create(deltaStore.open(localWaveletName), PERSIST_EXECUTOR); localWavelet = new LocalWaveletContainerImpl(localWaveletName, notifiee, Futures.immediateFuture(localWaveletState), localDomain, STORAGE_CONTINUATION_EXECUTOR); localWavelet.awaitLoad(); WaveletState remoteWaveletState = DeltaStoreBasedWaveletState.create(deltaStore.open(remoteWaveletName), PERSIST_EXECUTOR); remoteWavelet = new RemoteWaveletContainerImpl(remoteWaveletName, notifiee, Futures.immediateFuture(remoteWaveletState), STORAGE_CONTINUATION_EXECUTOR); remoteWavelet.awaitLoad(); }
final DeltaStore deltaStore = new MemoryDeltaStore(); final DeltaStoreTransient deltaStoreTransient = new MemoryDeltaStore(); final Executor waveletLoadExecutor = MoreExecutors.sameThreadExecutor(); final Executor persistExecutor = MoreExecutors.sameThreadExecutor();
WaveDigester digester = new WaveDigester(conversationUtil); final DeltaStore deltaStore = new MemoryDeltaStore(); final Executor persistExecutor = MoreExecutors.sameThreadExecutor(); final Executor storageContinuationExecutor = MoreExecutors.sameThreadExecutor();
WaveDigester digester = new WaveDigester(conversationUtil); final DeltaStore deltaStore = new MemoryDeltaStore(); final Executor persistExecutor = MoreExecutors.sameThreadExecutor(); final Executor storageContinuationExecutor = MoreExecutors.sameThreadExecutor();
final DeltaStore deltaStore = new MemoryDeltaStore(); final Executor waveletLoadExecutor = MoreExecutors.sameThreadExecutor(); final Executor persistExecutor = MoreExecutors.sameThreadExecutor();
@Override protected void setUp() throws Exception { super.setUp(); addParticipantOp = ProtocolWaveletOperation.newBuilder() .setAddParticipant(AUTHOR) .build(); // An empty blip operation - creates a new document. addBlipOp = ProtocolWaveletOperation.newBuilder().setMutateDocument( MutateDocument.newBuilder().setDocumentId(BLIP_ID).setDocumentOperation( ProtocolDocumentOperation.newBuilder().build())).build(); WaveletNotificationSubscriber notifiee = mock(WaveletNotificationSubscriber.class); DeltaStore deltaStore = new MemoryDeltaStore(); WaveletState waveletState = DeltaStoreBasedWaveletState.create(deltaStore.open(WAVELET_NAME), PERSIST_EXECUTOR); AccessController accessController = mock(AccessController.class); wavelet = new LocalWaveletContainerImpl(WAVELET_NAME, notifiee, Futures.immediateFuture(waveletState), null, STORAGE_CONTINUATION_EXECUTOR, accessController); wavelet.awaitLoad(); }
@Override protected void setUp() throws Exception { super.setUp(); addParticipantOp = ProtocolWaveletOperation.newBuilder() .setAddParticipant(AUTHOR) .build(); // An empty blip operation - creates a new document. addBlipOp = ProtocolWaveletOperation.newBuilder().setMutateDocument( MutateDocument.newBuilder().setDocumentId(BLIP_ID).setDocumentOperation( ProtocolDocumentOperation.newBuilder().build())).build(); WaveletNotificationSubscriber notifiee = mock(WaveletNotificationSubscriber.class); DeltaStore deltaStore = new MemoryDeltaStore(); WaveletState waveletState = DeltaStoreBasedWaveletState.create(deltaStore.open(WAVELET_NAME), PERSIST_EXECUTOR); wavelet = new LocalWaveletContainerImpl(WAVELET_NAME, notifiee, Futures.immediateFuture(waveletState), null, STORAGE_CONTINUATION_EXECUTOR); wavelet.awaitLoad(); }