org.greencheek.caching.herdcache.CacheWithExpiry Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of herdcache Show documentation
Show all versions of herdcache Show documentation
A cache that uses futures to prevent thundering herds to your backend service
package org.greencheek.caching.herdcache;
import com.google.common.util.concurrent.ListenableFuture;
import com.google.common.util.concurrent.ListeningExecutorService;
import java.time.Duration;
import java.util.function.Supplier;
/**
* Created by dominictootell on 23/08/2014.
*/
public interface CacheWithExpiry extends Cache {
public ListenableFuture apply(String key, Supplier computation, Duration timeToLive, ListeningExecutorService executorService);
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy