@Override public <T> ICompletableFuture<ReadResultSet<T>> readFromEventJournal( long startSequence, int minSize, int maxSize, int partitionId, Predicate<? super EventJournalCacheEvent<K, V>> predicate, Projection<? super EventJournalCacheEvent<K, V>, ? extends T> projection ) { if (maxSize < minSize) { throw new IllegalArgumentException("maxSize " + maxSize + " must be greater or equal to minSize " + minSize); } final SerializationService ss = getSerializationService(); final ClientMessage request = CacheEventJournalReadCodec.encodeRequest( nameWithPrefix, startSequence, minSize, maxSize, ss.toData(predicate), ss.toData(projection)); final ClientInvocationFuture fut = new ClientInvocation(getClient(), request, getName(), partitionId).invoke(); return new ClientDelegatingFuture<ReadResultSet<T>>(fut, ss, eventJournalReadResponseDecoder); }
@Override public <T> ICompletableFuture<ReadResultSet<T>> readFromEventJournal( long startSequence, int minSize, int maxSize, int partitionId, Predicate<? super EventJournalCacheEvent<K, V>> predicate, Projection<? super EventJournalCacheEvent<K, V>, ? extends T> projection ) { if (maxSize < minSize) { throw new IllegalArgumentException("maxSize " + maxSize + " must be greater or equal to minSize " + minSize); } final SerializationService ss = getSerializationService(); final ClientMessage request = CacheEventJournalReadCodec.encodeRequest( nameWithPrefix, startSequence, minSize, maxSize, ss.toData(predicate), ss.toData(projection)); final ClientInvocationFuture fut = new ClientInvocation(getClient(), request, getName(), partitionId).invoke(); return new ClientDelegatingFuture<ReadResultSet<T>>(fut, ss, eventJournalReadResponseDecoder); }