fixed compilation

pull/1821/head
Nikita 6 years ago
parent b1ae9ec044
commit de8c1715a4

@ -34,23 +34,10 @@ import org.redisson.command.CommandReactiveExecutor;
import io.netty.buffer.ByteBuf; import io.netty.buffer.ByteBuf;
import reactor.core.publisher.Flux; import reactor.core.publisher.Flux;
import reactor.core.publisher.Mono;
/** /**
* <p>Set-based cache with ability to set TTL for each entry via *
* {@link #add(Object, long, TimeUnit)} method.
* And therefore has an complex lua-scripts inside.
* Uses map(value_hash, value) to tie with sorted set which contains expiration record for every value with TTL.
* </p>
*
* <p>Current Redis implementation doesn't have set entry eviction functionality.
* Thus values are checked for TTL expiration during any value read operation.
* If entry expired then it doesn't returns and clean task runs hronous.
* Clean task deletes removes 100 expired entries at once.
* In addition there is {@link org.redisson.eviction.EvictionScheduler}. This scheduler
* deletes expired entries in time interval between 5 seconds to 2 hours.</p>
*
* <p>If eviction is not required then it's better to use {@link org.redisson.api.RSet}.</p>
*
* @author Nikita Koksharov * @author Nikita Koksharov
* *
* @param <V> value * @param <V> value
@ -88,7 +75,7 @@ public class RedissonSetCacheReactive<V> {
public Publisher<Integer> addAll(Collection<? extends V> c) { public Publisher<Integer> addAll(Collection<? extends V> c) {
if (c.isEmpty()) { if (c.isEmpty()) {
return Streams.just(0); return Mono.just(0);
} }
long score = 92233720368547758L - System.currentTimeMillis(); long score = 92233720368547758L - System.currentTimeMillis();

Loading…
Cancel
Save