Fri. May 29th, 2020

caffeine 2.8.4 releases, A high performance caching library for Java 8

1 min read

Caffeine is a high-performance Java 8 based caching library providing a near optimal hit rate.

caffeine

A Cache is similar to ConcurrentMap, but not quite the same. The most fundamental difference is that a ConcurrentMap persists all elements that are added to it until they are explicitly removed. A Cache on the other hand is generally configured to evict entries automatically, in order to constrain its memory footprint. In some cases a LoadingCache or AsyncLoadingCache can be useful even if it doesn’t evict entries, due to its automatic cache loading.

Cache

Caffeine provides an in-memory cache using a Google Guava inspired API. The improvements draw on our experience designing Guava’s cache and ConcurrentLinkedHashMap.

Features at a Glance

Caffeine provides flexible construction to create a cache with a combination of the following features:

Caffeine 2.8.4 has been released.

Changelog

Cache

  • Schedule maintenance on an absent getIfPresent if there is pending work (#420)

Download