# ben-manes/caffeine

A high performance caching library for Java

Repository: https://github.com/ben-manes/caffeine
Canonical: https://ross.abutalabs.com/products/caffeine
Language: Java
License: Apache-2.0
License Family: permissive
Last push: 2026-08-25T07:49:36+00:00

## Health v2 (maintenance only)
Score: 85/100 (v2, computed 2026-09-03T02:20:16.233290+00:00)
- activity 99, release rhythm 58, longevity 100
- inputs: {"age_days": 4281, "days_push": 8, "days_rel": 123, "gap_med": 124.5, "n_releases_24m": 5}
- flags: none
- formula: round(0.45*activity + 0.35*rhythm + 0.20*longevity); archived -> min(score, 10)

## Adoption (not part of the score)
Stars 17834, forks 1710 (observed 2026-08-28T04:11:20.462604+00:00)

## What it is
Caffeine is a high-performance, near-optimal in-memory caching library for Java with a Guava-inspired API. It supports size-based eviction, time-based expiration, asynchronous loading and refreshing, reference-based keys/values, eviction listeners, and access statistics.

## Use cases
- cache expensive computation results in memory
- evict entries when a maximum cache size is exceeded
- expire cache entries after a time-to-live
- asynchronously refresh stale cache entries
- track cache hit and miss statistics
- replace Guava cache for better performance

## When to choose
- you need a fast in-memory cache on the JVM
- you want Guava-like caching with better hit rates
- you need flexible eviction, expiration, and refresh policies

## When to avoid
- you need a distributed or persistent cache
- your application is not on the JVM

## Facets
- artifact type: library
- maturity: stable
- function: caching
- domain: performance, developer-tools, backend
- platform: jvm
- tags: in-memory-cache, eviction, guava-inspired, jcache

## Member repositories
- ben-manes/caffeine (main) score 85

## Provenance
- Observed fields: from GitHub, fetched 2026-08-28T04:11:20.462604+00:00.
- Health v2: computed from the inputs above; adoption is never an input.
- Inferred fields (summary, facets, guidance): AI-extracted, prompt v1, taxonomy v1, on 2026-08-29T17:02:26.566270+00:00, confidence not recorded.
  - readme: https://github.com/ben-manes/caffeine (fetched 2026-08-28T04:11:20.462604+00:00, sha cde31f6bf3c5)
- Data as of 2026-08-30T08:39:29.467469+00:00.
