org.cache2k:cache2k-jcache-parent

cache2k is a well engineered high performance in-memory Java cache. It implements latest eviction algorithms and coding techniques to achieve performance about 10 times better then existing cache solutions. cache2k comes with a clean and concise API. The API is currently still evolving until version 1.0 is reached.


Keywords
android, android-library, cache, java, java-library
License
Apache-2.0

Documentation

License Stack Overflow Maven Central CircleCI

cache2k Java Caching

cache2k is an in-memory high performance Java Caching library.

  Cache<String,String> cache = new Cache2kBuilder<String, String>() {}
    .expireAfterWrite(5, TimeUnit.MINUTES)    // expire/refresh after 5 minutes
    .setupWith(UniversalResiliencePolicy::enable, b -> b // enable resilience policy
      .resilienceDuration(30, TimeUnit.SECONDS)          // cope with at most 30 seconds
                                                         // outage before propagating 
                                                         // exceptions
    )
    .refreshAhead(true)                       // keep fresh when expiring
    .loader(this::expensiveOperation)         // auto populating function
    .build();

For a detailed introduction continue with Getting Started.

Features at a glance

Integrations

More...

For more documentation and latest news, see the cache2k homepage.

Contributing

See the Contributor Guide.