24

还在用Guava Cache?它才是Java本地缓存之王-Java_老男孩

 3 years ago
source link: https://blog.51cto.com/14230003/2531318
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
提到本地缓存,大家都能想到GuavaCache,他的优点是封装了get,put操作;提供线程安全的缓存操作;提供过期策略;提供回收策略;缓存监控。当缓存的数据超过最大值时,使用LRU算法替换。这一篇我们将要谈到一个新的本地缓存框架:CaffeineCache。它也是站在巨人的肩膀上-GuavaCache,借着他的思想优化了算法发展而来。本篇文章主要介绍CaffineCache的使用方式,以及Caf

About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK